2 /* This file is part of
3 * ======================================================
5 * LyX, The Document Processor
7 * Copyright 1995-2000 The LyX Team
9 * ======================================================*/
11 #ifndef COLOR_HANDLER_H
12 #define COLOR_HANDLER_H
18 // This is only included to provide stuff for the non-public sections
21 #include "PainterBase.h"
27 class LyXColorHandler {
34 unsigned long colorPixel(LColor::color c);
36 GC getGCForeground(LColor::color c);
38 GC getGCLinepars(PainterBase::line_style,
39 PainterBase::line_width, LColor::color c);
40 /// update the cache after a color definition change
41 void updateColor(LColor::color c);
49 GC colorGCcache[LColor::ignore + 1];
51 typedef std::map<int, GC> LineGCCache;
53 LineGCCache lineGCcache;
59 extern LyXColorHandler * lyxColorHandler;