View Issue Details

IDProjectCategoryView StatusLast Update
0021759LazarusLCLpublic2012-04-19 00:00
ReporterDavid JenkinsAssigned ToPaul Ishenin 
PrioritynormalSeverityfeatureReproducibilityN/A
Status closedResolutionfixed 
Product Version0.9.30.5 (SVN)Product Build 
Target VersionFixed in Version1.1 (SVN) 
Summary0021759: Restore brush style to bsSolid on bsClear in TBrush.SetColor
DescriptionDelphi sets TBrush.Style to bsSolid when SetColor is called with bsClear.

See attached patch against rev 36681
TagsNo tags attached.
Fixed in Revision36808,36809
LazTarget-
WidgetsetCarbon
Attached Files
  • brush.inc.patch (595 bytes)
    --- /opt/src/laz-svn/lcl/include/brush.inc	2011-04-18 12:35:17.000000000 
    +++ /usr/local/share/lazarus/lcl/include/brush.inc	2012-03-12 15:18:02.000000000 
    @@ -38,12 +38,13 @@
       Returns:  nothing
     
       Sets the style of a brush
      ------------------------------------------------------------------------------}
     procedure TBrush.SetColor(Value: TColor);
     begin
    +  if Style = bsClear then SetStyle(bsSolid);
       if FColor <> Value then
         SetColor(Value, TColorToFPColor(Value));
     end;
     
     {------------------------------------------------------------------------------
       Method: TBrush.SetStyle
    
    brush.inc.patch (595 bytes)

Activities

2012-04-13 22:34

 

brush.inc.patch (595 bytes)
--- /opt/src/laz-svn/lcl/include/brush.inc	2011-04-18 12:35:17.000000000 
+++ /usr/local/share/lazarus/lcl/include/brush.inc	2012-03-12 15:18:02.000000000 
@@ -38,12 +38,13 @@
   Returns:  nothing
 
   Sets the style of a brush
  ------------------------------------------------------------------------------}
 procedure TBrush.SetColor(Value: TColor);
 begin
+  if Style = bsClear then SetStyle(bsSolid);
   if FColor <> Value then
     SetColor(Value, TColorToFPColor(Value));
 end;
 
 {------------------------------------------------------------------------------
   Method: TBrush.SetStyle
brush.inc.patch (595 bytes)

Paul Ishenin

2012-04-16 08:14

manager   ~0058644

I made it a bit different from your patch.
Please test and close if ok.

Issue History

Date Modified Username Field Change
2012-04-13 22:34 David Jenkins New Issue
2012-04-13 22:34 David Jenkins File Added: brush.inc.patch
2012-04-13 22:34 David Jenkins Widgetset => Carbon
2012-04-16 08:14 Paul Ishenin Fixed in Revision => 36808,36809
2012-04-16 08:14 Paul Ishenin LazTarget => -
2012-04-16 08:14 Paul Ishenin Status new => resolved
2012-04-16 08:14 Paul Ishenin Fixed in Version => 1.1 (SVN)
2012-04-16 08:14 Paul Ishenin Resolution open => fixed
2012-04-16 08:14 Paul Ishenin Assigned To => Paul Ishenin
2012-04-16 08:14 Paul Ishenin Note Added: 0058644
2012-04-19 00:00 David Jenkins Status resolved => closed