Re: [QGIS-Developer] QgsSymbolButton/QgsFontButton no menu?

2018-12-17 Thread Jonas
Hi Nyall,

ok, thank you!

Jonas

> On 15. Dec 2018, at 22:41, Nyall Dawson  wrote:
> 
> On Sat, 15 Dec 2018 at 20:50, Jonas  wrote:
>> 
>> Hi,
>> 
>> i am currently working on fixing the inner paddings of the ToolButtons for
>> Symbols (QgsSymbolButton) and Fonts (QgsFontButton) on non-windows platforms
>> (the fontbutton for macOS has been fixed in
>> https://github.com/qgis/QGIS/pull/8605
>>   ).
>> 
>> 
>> 
>> can somebody explain to me the rationale to have differing icon widths if
>> the button has no menu?
>> 
>> see
>> https://github.com/qgis/QGIS/blob/8a0a745677a8ff2c4631f451c9ed8fd7580ec220/src/gui/qgssymbolbutton.cpp#L468
>> 
> 
> I don't think these are required, and are just remnants of code copied
> originally from the color button. As you've rightly concluded, it's
> not possible to use the font/symbol button widgets without the menus.
> 
> Nyall
> 
>> 
>> i could imagine this would make sense if you could remove the arrow on the
>> right to make the icon wider then, but i actually found no way to do this in
>> c++ or python. but you can remove the menu without removing the arrow (eg
>> setting QgsFontButton.setMenu(None) in PyQGIS) which triggers the
>> alternative styling. it does not make sense but it makes the button look
>> weird and also ... blurry on all platforms ?!??
>> 
>> i would like to fix the padding and think that removing the check altogether
>> is fine, but i am reluctant to move on as i am new around here.
>> 
>> can somebody explain if there is a use case for the non-menu styling? Thanks
>> 
>> Jonas (iona5)
>> 
>> 
>> 
>> 
>> 
>> 
>> --
>> Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-Developer-f4099106.html
>> ___
>> QGIS-Developer mailing list
>> QGIS-Developer@lists.osgeo.org
>> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
>> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] QgsSymbolButton/QgsFontButton no menu?

2018-12-15 Thread Nyall Dawson
On Sat, 15 Dec 2018 at 20:50, Jonas  wrote:
>
> Hi,
>
> i am currently working on fixing the inner paddings of the ToolButtons for
> Symbols (QgsSymbolButton) and Fonts (QgsFontButton) on non-windows platforms
> (the fontbutton for macOS has been fixed in
> https://github.com/qgis/QGIS/pull/8605
>   ).
>
> 
>
> can somebody explain to me the rationale to have differing icon widths if
> the button has no menu?
>
> see
> https://github.com/qgis/QGIS/blob/8a0a745677a8ff2c4631f451c9ed8fd7580ec220/src/gui/qgssymbolbutton.cpp#L468
> 

I don't think these are required, and are just remnants of code copied
originally from the color button. As you've rightly concluded, it's
not possible to use the font/symbol button widgets without the menus.

Nyall

>
> i could imagine this would make sense if you could remove the arrow on the
> right to make the icon wider then, but i actually found no way to do this in
> c++ or python. but you can remove the menu without removing the arrow (eg
> setting QgsFontButton.setMenu(None) in PyQGIS) which triggers the
> alternative styling. it does not make sense but it makes the button look
> weird and also ... blurry on all platforms ?!??
>
> i would like to fix the padding and think that removing the check altogether
> is fine, but i am reluctant to move on as i am new around here.
>
> can somebody explain if there is a use case for the non-menu styling? Thanks
>
> Jonas (iona5)
>
>
>
>
>
>
> --
> Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-Developer-f4099106.html
> ___
> QGIS-Developer mailing list
> QGIS-Developer@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

[QGIS-Developer] QgsSymbolButton/QgsFontButton no menu?

2018-12-15 Thread Jonas
Hi,

i am currently working on fixing the inner paddings of the ToolButtons for
Symbols (QgsSymbolButton) and Fonts (QgsFontButton) on non-windows platforms
(the fontbutton for macOS has been fixed in 
https://github.com/qgis/QGIS/pull/8605
  ).

 

can somebody explain to me the rationale to have differing icon widths if
the button has no menu?

see 
https://github.com/qgis/QGIS/blob/8a0a745677a8ff2c4631f451c9ed8fd7580ec220/src/gui/qgssymbolbutton.cpp#L468

  

i could imagine this would make sense if you could remove the arrow on the
right to make the icon wider then, but i actually found no way to do this in
c++ or python. but you can remove the menu without removing the arrow (eg
setting QgsFontButton.setMenu(None) in PyQGIS) which triggers the
alternative styling. it does not make sense but it makes the button look
weird and also ... blurry on all platforms ?!??

i would like to fix the padding and think that removing the check altogether
is fine, but i am reluctant to move on as i am new around here.

can somebody explain if there is a use case for the non-menu styling? Thanks

Jonas (iona5)


 



--
Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-Developer-f4099106.html
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer