Display XML on bitmap

Cancelado Publicado May 4, 2009 Pagado a la entrega
Cancelado Pagado a la entrega

I'm developing WinMobile application with printing suppot.

One of subtasks is customizable reports. Printer API is very specific.

It can print text, but only 4 font sizes; left, right, centered, no word wrap.

Also it can print bitmaps.

So idea is to draw report on bitmap and then print it by API.

From you, I need XML based report template language. (I think better to use HTML subset. May be <DIV> <IMG> <TABLE> will be enough.)

And I need module that draw this template on bitmap.

From report templates I need:

1. Blocks of text (<DIV>?) with

- bounding rect (opt)

- background color (opt)

- background image (opt)

- fonts (color, size, weight, underline and so on)

- word wrap

- text alignment (left, right, center, justify)

- absolute positioning

- relative positioning

2. Images. <IMG>

- no stretch or scale

- crop;

- width/height required

- centered or aligned

3. Tables:

- width

- height

- row/col spans

- borders

That's all for now.

---------------

3rd party opensource libraries acceptable.

You can use GDI or GDI+

You can use C++, C# or VB.NET

---------------

If you know (or plan to use) 3rd party opensource project that can help, point this in your bid.

---------------

Ask if you have any question.

I made some investigations, so I need class with interface:
class CXMLPrinter {
public:
CXMLPrinter();

//Layout xml for specified width and return calculated height
int Layout(String xml, int width);

BOOL Draw(RECT bounds, String fileName) {
Bitmap bmp(bounds.width, bounds.height, Format32bitRGB);
if (!PrepareBitmap(bounds, bmp))
return false;
if (!CreateBMP((bounds.width, bounds.height, bmp.scanline0, fileName))
return false;
return true;
}

protected:

BOOL PrepareBitmap(RECT bounds, Bitmap bmp);
}

I'll provide DLL with conversion routine:
VB.NET signature:
<DllImport("BMPCreator.dll")> _
Public Shared Function CreateBMP( _
ByVal iWidth As Integer, _
ByVal iHeight As Integer, _
ByVal pScanLine0Ptr As IntPtr, _
ByVal sFile As String) As Integer
End Function

C++ signature:
BMPCREATOR_API int CreateBMP(int width, int height, BYTE *pScanLine0Ptr, WCHAR *fName);

.NET Programación en C XML

Nº del proyecto: #429368

Sobre el proyecto

4 propuestas Proyecto remoto Activo Feb 19, 2010

4 freelancers están ofertando un promedio de $200 por este trabajo

Shot

Experience of programming on various versions of C 20+ years. Wide experience of work with images.

$250 USD en 30 días
(10 comentarios)
5.8
Yurilad

I can help you.

$200 USD en 15 días
(19 comentarios)
5.0
Phoenix87

Hi, please refer to the PM for details of the bid. Thank you Vivek

$250 USD en 7 días
(1 comentario)
0.0
ruLab

Hello I can do your project

$200 USD en 7 días
(0 comentarios)
2.5
vuhaianh

Hello Sir! I can do this project for U. I have some interesting ideas for your problem. Im happy to discuss with you more about this. Regard Anh

$150 USD en 5 días
(0 comentarios)
0.0