From 493f366765cf3bc8d1ff166b874433a8c0a900aa Mon Sep 17 00:00:00 2001 From: Tomaz Canabrava Date: Mon, 16 Sep 2013 19:21:13 -0300 Subject: Use the same line dimensions as the profile, on the planner. The Planner should be 'almost' like the profile, with the possibility to use the mouse and keyboard to input a new plan, so this is a bit of 'getting there.' I don't like too much code duplication but since the current Profile Graphics is a crude cut-and-paste from the old Cairo backend, it's easyer to start from scratch and have it well organized as Qt code. Signed-off-by: Tomaz Canabrava --- qt-ui/graphicsview-common.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'qt-ui/graphicsview-common.cpp') diff --git a/qt-ui/graphicsview-common.cpp b/qt-ui/graphicsview-common.cpp index fbe196e98..30b9ccb08 100644 --- a/qt-ui/graphicsview-common.cpp +++ b/qt-ui/graphicsview-common.cpp @@ -55,3 +55,8 @@ void fill_profile_color() profile_color[CALC_CEILING_DEEP] = COLOR(APPLE1_HIGH_TRANS, BLACK1_HIGH_TRANS, APPLE1_HIGH_TRANS); #undef COLOR } + +QColor getColor(const color_indice_t i, bool isGrayscale = false) +{ + return profile_color[i].at((isGrayscale) ? 1 : 0); +} -- cgit v1.2.3-70-g09d2