mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-05-09 00:12:53 +02:00
gtk2: try to draw tree signs with requested size
git-svn-id: trunk@17233 -
This commit is contained in:
parent
3b57a81d36
commit
2ddbc5600b
@ -455,8 +455,22 @@ begin
|
|||||||
{$ifndef gtk1}
|
{$ifndef gtk1}
|
||||||
if Painter = gptExpander then
|
if Painter = gptExpander then
|
||||||
begin
|
begin
|
||||||
Area.width := ExpanderSize;
|
// Better to draw expander with the ExpanderSize, but sometimes it
|
||||||
Area.height := ExpanderSize;
|
// will not look very well. The best can we do is to use the same odd/even
|
||||||
|
// amount of pixels => expand/shrink area.width and area.height a bit
|
||||||
|
|
||||||
|
// Area.width := ExpanderSize;
|
||||||
|
if Odd(Area.width) <> Odd(ExpanderSize) then
|
||||||
|
if Area.width < ExpanderSize then
|
||||||
|
inc(Area.width)
|
||||||
|
else
|
||||||
|
dec(Area.width);
|
||||||
|
// Area.height := ExpanderSize;
|
||||||
|
if Odd(Area.height) <> Odd(ExpanderSize) then
|
||||||
|
if Area.height < ExpanderSize then
|
||||||
|
inc(Area.height)
|
||||||
|
else
|
||||||
|
dec(Area.height);
|
||||||
end;
|
end;
|
||||||
{$endif}
|
{$endif}
|
||||||
case Painter of
|
case Painter of
|
||||||
|
Loading…
Reference in New Issue
Block a user