From: <yu...@us...> - 2009-07-02 04:53:56
|
Revision: 3978 http://hugin.svn.sourceforge.net/hugin/?rev=3978&view=rev Author: yuv Date: 2009-07-01 10:33:52 +0000 (Wed, 01 Jul 2009) Log Message: ----------- removed rainbow and use single color to qualify quality of link between images. Modified Paths: -------------- hugin/trunk/src/hugin1/hugin/CPImagesComboBox.cpp Modified: hugin/trunk/src/hugin1/hugin/CPImagesComboBox.cpp =================================================================== --- hugin/trunk/src/hugin1/hugin/CPImagesComboBox.cpp 2009-07-01 07:10:00 UTC (rev 3977) +++ hugin/trunk/src/hugin1/hugin/CPImagesComboBox.cpp 2009-07-01 10:33:52 UTC (rev 3978) @@ -197,17 +197,32 @@ x=max<wxCoord>(5,x); const wxPen * oldPen = & dc.GetPen(); const wxBrush * oldBrush= & dc.GetBrush(); - //inner rectangle, proportional to max cp error (max. 10) and with dither gradient color + //inner rectangle with color proportional to max cp error (max. 10) wxPen MyPen(wxColour(255,0,0),1,wxSOLID); wxBrush MyBrush(wxColour(255,0,0),wxSOLID); // half the rectangle int half=rect.width/10; - // gradient steps + // color steps double step_red=255.0/half; double step_green=192.0/half; - // gradient starting color + // starting color double red=255.0; double green=0.0; + if(x<half) + { + green=green+x*step_green; + } + else + { + green=192.0; + red=red-x*step_red; + } + MyPen.SetColour(wxColour(red,green,0)); + MyBrush.SetColour(wxColour(red,green,0)); + dc.SetPen(MyPen); + dc.SetBrush(MyBrush); + dc.DrawRectangle(rect.x+0.75*rect.width,rect.y+rect.height/6+1,x,2*rect.height/3); +/* for(int i=0;i<x;i++) { MyPen.SetColour(wxColour(red,green,0)); @@ -227,7 +242,7 @@ red=red-step_red; } } - +*/ //outer rectangle, same colour as text MyPen.SetColour(dc.GetTextForeground()); dc.SetPen(MyPen); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |