Re: [Gambas-user] Gambas3 Printing - text width SOLVED

2011-12-17 Thread Bill-Lancaster
OK, didn't try hard enough! Paint.Font.RichTextWidth(TextString) should do the trick. -- View this message in context: http://old.nabble.com/Gambas3-Printing---text-width-tp32991752p32992108.html Sent from the gambas-user mailing list archive at Nabble.com. ---

Re: [Gambas-user] Gambas3 Printing - text width

2011-12-17 Thread Fabien Bodard
2011/12/17 Bill-Lancaster : > > I'm using > >          Paint.DrawRichText(MoneyValue, x, y) > > and want to have money values right justified (ideally '.' justified). > > The Align.Right option doesn't help. yes you need to specify right relative to ??? you need to specify the width and height o

[Gambas-user] Gambas3 Printing - text width

2011-12-17 Thread Bill-Lancaster
I'm using Paint.DrawRichText(MoneyValue, x, y) and want to have money values right justified (ideally '.' justified). The Align.Right option doesn't help. Any ideas? Gambas 2.99.6, qt4 -- View this message in context: http://old.nabble.com/Gambas3-Printing---text-width-tp3299175

Re: [Gambas-user] Gambas3 Printing

2010-12-29 Thread Michael
Benoit, Have you managed to look at the GTK+ printer dialog problems? With further testing I set the orientation to "Landscape" in code and the paper was correctly oriented. IE The long edge was horizontal but the Paint.Width and Paint.Height did not change so the printing was truncated in width

Re: [Gambas-user] Gambas3 Printing

2010-12-05 Thread Benoît Minisini
> > And there is another bug in gb.qt4 printing: the font size is not > resolution independant, whereas it should be the contrary according the > documentation (i.e. a 50 points font is very small, as if its height is > actually 50 pixels.). I must investigate too... > The font size bug when pri

Re: [Gambas-user] Gambas3 Printing

2010-12-04 Thread Benoît Minisini
> Hi Fabien, > I've got printing to work ok but positioning objects on the page is > difficult compared to Gambas2. The Paint.Width and Paint.Height values > seem to bear no relation to pixels or mm. On A4 paper I get values of > 559 and 760 approx. What units are used here? (My printer resolution

Re: [Gambas-user] Gambas3 Printing

2010-12-04 Thread Michael
Hi Fabien, I've got printing to work ok but positioning objects on the page is difficult compared to Gambas2. The Paint.Width and Paint.Height values seem to bear no relation to pixels or mm. On A4 paper I get values of 559 and 760 approx. What units are used here? (My printer resolution is 300)

Re: [Gambas-user] Gambas3 Printing

2010-12-03 Thread Michael
Thanks Fabien, I am getting there slowly. Can print in a small test app but in a real world app I just get blank pages. One of the problems I overcame was the different units used by the printer and Paint routines. In Gambas2 the printer and Draw objects both used pixels. Now we seem to have a m

Re: [Gambas-user] Gambas3 Printing

2010-12-03 Thread Fabien Bodard
Private hPrint As New Printer As "Printer" Public Sub Form_Open() If Not hPrint.Configure() Then hPrint.Print Endif End Public Sub Printer_Begin() hPrint.Count = 1 End Public Sub Printer_Draw() Paint.Font.Size = 12 Paint.Text("Hello", 30, 50) Paint.fill End Public Sub Pri

[Gambas-user] Gambas3 Printing

2010-12-03 Thread Michael
Does anybody have any experience of printing with Gambas3? My sample code is below and the result is: Calling .Configure fires the _End event. Then the _Begin, _Paginate and _Draw events all fire. Then I get an error "(Test:4193): Gtk-CRITICAL **: IA__gtk_print_context_get_cairo_context: assertion