[Igarden-commit] CommonSource/YAAFExtensions RGGLSVGDraw.cpp, 1.26.2.6, 1.26.2.7 RGGLSVGDraw.h, 1.8
Status: Beta
Brought to you by:
jlbedell
|
From: Jeffrey B. <jlb...@us...> - 2006-11-29 12:30:01
|
Update of /cvsroot/igarden/CommonSource/YAAFExtensions In directory sc8-pr-cvs2.sourceforge.net:/tmp/cvs-serv16846 Modified Files: Tag: Release_branch_v1 RGGLSVGDraw.cpp RGGLSVGDraw.h Log Message: Correct problem with color disappearing from some views Index: RGGLSVGDraw.cpp =================================================================== RCS file: /cvsroot/igarden/CommonSource/YAAFExtensions/RGGLSVGDraw.cpp,v retrieving revision 1.26.2.6 retrieving revision 1.26.2.7 diff -C2 -d -r1.26.2.6 -r1.26.2.7 *** RGGLSVGDraw.cpp 15 Nov 2006 12:18:09 -0000 1.26.2.6 --- RGGLSVGDraw.cpp 29 Nov 2006 12:29:58 -0000 1.26.2.7 *************** *** 74,78 **** void GetInitialSize(double &width, double &length); void Init(XGFileSpecifier &spec, middleType_t defaultType); ! ErrorCode GetDisplayList(double xSize, double ySize, double rotate, bool forcePastBounds, long &result); void EnableColor(bool useColor); --- 74,78 ---- void GetInitialSize(double &width, double &length); void Init(XGFileSpecifier &spec, middleType_t defaultType); ! ErrorCode GetDisplayList(double xSize, double ySize, double rotate, bool forcePastBounds, allowColor_t color, long &result); void EnableColor(bool useColor); *************** *** 144,148 **** _cache = new SVGCacheEntry; } ! _cache->EnableColor(color == kUseColor); } --- 144,148 ---- _cache = new SVGCacheEntry; } ! _color = color; } *************** *** 164,168 **** ptr = GetCacheEntry(spec, defaultType); ! ptr->GetDisplayList(xSize, ySize, rotate, forcePastBounds, displayList); if(ec == yaaf::KYAAFNoError) { --- 164,168 ---- ptr = GetCacheEntry(spec, defaultType); ! ptr->GetDisplayList(xSize, ySize, rotate, forcePastBounds, _color, displayList); if(ec == yaaf::KYAAFNoError) { *************** *** 879,883 **** ! ErrorCode SVGCacheEntry::GetDisplayList(double xSize, double ySize, double rotate, bool forcePastBounds, long &result) { XGXMLObject *parseTree; --- 879,883 ---- ! ErrorCode SVGCacheEntry::GetDisplayList(double xSize, double ySize, double rotate, bool forcePastBounds, allowColor_t color, long &result) { XGXMLObject *parseTree; *************** *** 886,889 **** --- 886,890 ---- ErrorCode ec = yaaf::KYAAFNoError; bool sameContext = false; + bool allowColor = (color == kUseColor); ComputeSizes(); *************** *** 951,956 **** #endif ! if(parseTree != NULL && !_hasDisplayList && (xSize != _planSize.x || ySize != _planSize.y || rotate != _rotate || !sameContext )) { _planSize.x = xSize; _planSize.y = ySize; --- 952,958 ---- #endif ! if(parseTree != NULL && !_hasDisplayList && (xSize != _planSize.x || ySize != _planSize.y || rotate != _rotate || !sameContext || allowColor != _allowColor)) { + _allowColor = allowColor; _planSize.x = xSize; _planSize.y = ySize; *************** *** 1848,1852 **** const char *val; val = data->GetArgValue("style"); ! if(CIstrstr(val, "stroke:white") || CIstrstr(val, "stroke:#FFFFFF") || CIstrstr(val, "stroke:none") || CIstrstr(val, "stroke-opacity:0")) return false; else --- 1850,1856 ---- const char *val; val = data->GetArgValue("style"); ! if(!_allowColor) ! return true; // Need to draw edges ! else if(CIstrstr(val, "stroke:white") || CIstrstr(val, "stroke:#FFFFFF") || CIstrstr(val, "stroke:none") || CIstrstr(val, "stroke-opacity:0")) return false; else *************** *** 1928,1932 **** { long color; ! double red, green, blue; fill++; --- 1932,1936 ---- { long color; ! float red, green, blue; fill++; Index: RGGLSVGDraw.h =================================================================== RCS file: /cvsroot/igarden/CommonSource/YAAFExtensions/RGGLSVGDraw.h,v retrieving revision 1.8.2.1 retrieving revision 1.8.2.2 diff -C2 -d -r1.8.2.1 -r1.8.2.2 *** RGGLSVGDraw.h 15 Nov 2006 12:18:09 -0000 1.8.2.1 --- RGGLSVGDraw.h 29 Nov 2006 12:29:58 -0000 1.8.2.2 *************** *** 72,75 **** --- 72,76 ---- SVGCacheEntry *ComputeSizes(XGFileSpecifier &spec, middleType_t defaultType); SVGCacheEntry *GetCacheEntry(XGFileSpecifier &spec, middleType_t defaultType); + allowColor_t _color; }; |