kicad-developers team mailing list archive
-
kicad-developers team
-
Mailing list archive
-
Message #02579
pcbnew - pad transparency & changes in gr_basic.cpp
-
To:
kicad-devel@xxxxxxxxxxxxxxx
-
From:
"Marco Serantoni" <marco.serantoni@...>
-
Date:
Sat, 30 May 2009 10:59:22 -0000
-
User-agent:
eGroups-EW/0.82
After the changes that were committed there are some changes to do to the PAD drawing to make them also with an alpha.
Prerequisite of that is to change GRSetBrush to accept the Alpha channel.
After all those changes and after stressing committers i'm doing a link to show how looks pcbnew, just to let see the fruit of all this work: http://www.mdx4.org/uploads/elettronics/Kicad/2009-05-30-pcbnew.tiff
Thank you for the patience,
Marco
Index: gr_basic.cpp
===================================================================
--- gr_basic.cpp (revision 1796)
+++ gr_basic.cpp (working copy)
@@ -321,15 +321,10 @@
void GRSetBrush( wxDC* DC, int Color, int fill )
/***********************************************/
{
- Color &= MASKCOLOR; // Pour 32 couleurs Max
if( ForceBlackPen )
Color = BLACK;
wxBrush DrawBrush;
- DrawBrush.SetColour(
- ColorRefs[Color].m_Red,
- ColorRefs[Color].m_Green,
- ColorRefs[Color].m_Blue
- );
+ DrawBrush.SetColour(MakeColour( Color ));
if( fill )
DrawBrush.SetStyle( wxSOLID );
Index: class_pad_draw_functions.cpp
===================================================================
--- class_pad_draw_functions.cpp (revision 1796)
+++ class_pad_draw_functions.cpp (working copy)
@@ -205,6 +205,8 @@
if( ( m_Masque_Layer & ALL_CU_LAYERS ) == 0 )
DisplayIsol = FALSE;
+ SetAlpha(&color,170);
+
switch( GetShape() )
{
case PAD_CIRCLE:
Follow ups