[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Proxy for RadioButton
[Thread Prev] | [Thread Next]
- Subject: Re: Proxy for RadioButton
- From: Gianluigi <gradobag@xxxxxxxxxxx>
- Date: Mon, 23 Sep 2024 23:48:29 +0200
- To: user@xxxxxxxxxxxxxxxxxxxxxx
Il 23/09/24 20:54, Fabien Bodard ha scritto:
https://gambaswiki.org/wiki/comp/gb.qt4/style/paintoption?l=fr&nh <https://gambaswiki.org/wiki/comp/gb.qt4/style/paintoption?l=fr&nh> Note: Different toolkits behave differently with this function. As a general example if you supply width and height size as 32x32px QT5 will paint an option image 32x32px in size but GTK3 will only paint an image of 16x16px inside a 32x32 frame regardless of what size you request. To get a truly different size Option image with gtk3 you must paint the 16x16 Option and then stretch the image.
Hi Fabien, thanks for the reply and sorry for the delay, I watched Netflix with my wife :-) I can't stretch the image, I tried various ways (in fact SquareButton came to mind and I looked there too). Here are some of the tests: '--------------------------------- Private hPicTrue As Picture Private hPicFalse As Picture Public Sub _new() hPicTrue = New Picture(16, 16, True) hPicFalse = New Picture(16, 16, True) Paint.Begin(hPicTrue) Style.PaintOption(0, 0, 16, 16, True) Paint.DrawPicture(hPicTrue, 0, 0, 16, 16) ' Paint.StretchImage(hPicTrue.Image, 0, 0, 16, 16, Align.Center) Paint.End Paint.Begin(hPicFalse) Style.PaintOption(0, 0, 16, 16, False) Paint.DrawPicture(hPicFalse, 0, 0, 16, 16) ' Paint.StretchImage(hPicFalse.Image, 0, 0, 16, 16, Align.Center) Paint.End End Public Sub tato_Click() Action["check"].Picture = hPicFalse Last.Picture = hPicTrue End '-------------------------------- Private $himgTrue As Image Private $hImgFalse As Image Public Sub _new() Dim hPicTrue, hPicFalse As Picture hPicTrue = New Picture(16, 16, True) hPicFalse = New Picture(16, 16, True) Paint.Begin(hPicTrue) Style.PaintOption(0, 0, 16, 16, True) Paint.End $himgTrue = hPicTrue.Image.Stretch(16, 16) Paint.Begin(hPicFalse) Style.PaintOption(0, 0, 16, 16, False) Paint.End $hImgFalse = hPicFalse.Image.Stretch(16, 16) End Public Sub tato_Click() Action["check"].Picture = $hImgFalse.Picture Last.Picture = $himgTrue.Picture End I don't want to make a component painting on a DrawingArea... What am I doing wrong? Regards & Goodnight Gianluigi
Re: Proxy for RadioButton | Gianluigi <gradobag@xxxxxxxxxxx> |
Proxy for RadioButton | BB <adamnt42@xxxxxxxxx> |
Re: Proxy for RadioButton | Bruce Steers <bsteers4@xxxxxxxxx> |
Re: Proxy for RadioButton | Jussi Lahtinen <jussi.lahtinen@xxxxxxxxx> |
Re: Proxy for RadioButton | Bruce Steers <bsteers4@xxxxxxxxx> |
Re: Proxy for RadioButton | Jussi Lahtinen <jussi.lahtinen@xxxxxxxxx> |
Re: Proxy for RadioButton | Jussi Lahtinen <jussi.lahtinen@xxxxxxxxx> |
Re: Proxy for RadioButton | Gianluigi <gradobag@xxxxxxxxxxx> |
Re: Proxy for RadioButton | Jussi Lahtinen <jussi.lahtinen@xxxxxxxxx> |
Re: Proxy for RadioButton | Gianluigi <gradobag@xxxxxxxxxxx> |
Re: Proxy for RadioButton | Gianluigi <gradobag@xxxxxxxxxxx> |
Re: Proxy for RadioButton | Gianluigi <gradobag@xxxxxxxxxxx> |
Re: Proxy for RadioButton | Bruce Steers <bsteers4@xxxxxxxxx> |
Re: Proxy for RadioButton | Gianluigi <gradobag@xxxxxxxxxxx> |
Re: Proxy for RadioButton | Bruce Steers <bsteers4@xxxxxxxxx> |
Re: Proxy for RadioButton | Gianluigi <gradobag@xxxxxxxxxxx> |
Re: Proxy for RadioButton | Fabien Bodard <gambas.fr@xxxxxxxxx> |