Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-28 Thread Jussi Lahtinen
> Because you must to set explicitelly the background color. > > Picture =new picture(w,h,gb.transparent) > Ummm... no. There argument is boolean type for mask, and it doesn't change the issue. Even if you do it correctly; PictureBox1.Picture.Fill(Color.White) , it doesn't fix the limitation Beno

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-28 Thread Fabien Bodard
Because you must to set explicitelly the background color. Picture =new picture(w,h,gb.transparent) Le 28 août 2014 16:40, "Jussi Lahtinen" a écrit : > > > It seems picture of PictureBox doesn't like to be drew on. Not sure > why, > > > > The Picture property is NULL by default: it just owns a

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-28 Thread Jussi Lahtinen
> > It seems picture of PictureBox doesn't like to be drew on. Not sure why, > > The Picture property is NULL by default: it just owns a reference to a > Picture object you must create by yourself! > I noticed that and it wasn't the problem. This was the code I tried: PictureBox1.Picture = New Pi

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-28 Thread Benoît Minisini
Le 28/08/2014 13:55, Jussi Lahtinen a écrit : > It seems picture of PictureBox doesn't like to be drew on. Not sure why, The Picture property is NULL by default: it just owns a reference to a Picture object you must create by yourself! -- Benoît Minisini ---

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-28 Thread Jussi Lahtinen
It seems picture of PictureBox doesn't like to be drew on. Not sure why, but we have DrawingArea for that purpose... Anyway, here is proper way (this didn't work?): Dim tmp As New Picture(DrawingArea1.Width, DrawingArea1.Height) If Not bPrinter Then Draw.Begin(tmp) Draw.Clear mo

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-28 Thread abbat81
Hi Jussi, Draw.Begin(PictureBox1) -> Not a printable object Draw.Begin(PictureBox1.Picture) -> Null Object Any idea? Thanks for reply. -- View this message in context: http://gambas.8142.n7.nabble.com/DrawingArea-to-Picture-or-Image-tp47850p47874.html Sent from the gambas-user mailing l

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-27 Thread Jussi Lahtinen
I think just change this: 'Draw.Begin(DrawingArea1) Draw.Clear modCrBcode.PrintBarcode(txtBarcode.Text, Val(txtPosX.text), Val(txtPosY.text), Val(txtHeight.text), Val(txtWidth.text), True) 'Draw.End() To: Draw.Begin(PictureBox1) Draw.Clear modCrBcode.PrintBarcode(txtB

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-27 Thread Tobias Boege
On Wed, 27 Aug 2014, abbat81 wrote: > Thank you Tobi, > > But I could not understand it. > > Can you tell what to add to BarCode Example to reprint drawingarea > image/picture to PictureBox1? > This example is really messy (e.g. it assumes the drawing device is large enough to contain the barco

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-27 Thread abbat81
Thank you Tobi, But I could not understand it. Can you tell what to add to BarCode Example to reprint drawingarea image/picture to PictureBox1? Thaks in advance. -- View this message in context: http://gambas.8142.n7.nabble.com/DrawingArea-to-Picture-or-Image-tp47850p47854.html Sent fro

Re: [Gambas-user] DrawingArea to Picture or Image

2014-08-27 Thread Tobias Boege
On Wed, 27 Aug 2014, abbat81 wrote: > Hi, > > I tried to use BarCode Example to make a picture or image with barcode. > But I can't do it > > Can you help me? > >From all the questions which occur regularly on this list, I think this one is my favourite. Look at the archives: [0]. There is als

[Gambas-user] DrawingArea to Picture or Image

2014-08-27 Thread abbat81
Hi, I tried to use BarCode Example to make a picture or image with barcode. But I can't do it Can you help me? Thanks. Public Sub Button1_Click() Dim hPicture As New Picture(DrawingArea1.W, DrawingArea1.H) PictureBox1.Picture = hPicture End -- View this message in context: http://gam