Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2010-12-20 06:59:22 +0300
committerCampbell Barton <ideasman42@gmail.com>2010-12-20 06:59:22 +0300
commit3bed4cbf2b4c09dcb62197b8a8c4ec4224abc8b7 (patch)
treefc800fc89f29db4ac9d951ff148b8424c8cb7c73 /source/blender/editors/include/UI_resources.h
parent17f37dceccb99d7eb58f7c29908eeb2bd87cd7ff (diff)
fix [#25283] Edge length display difficult to read
- made theme colors for mesh edge len & face angle/area display. - use %g rather then %f for float display, trims unneeded zeros. - store cached 2d and 3d text color as bytes rather then floats, compare when drawing to avoid setting the context. - use unsigned char for more color functions, avoids casting to glColorubv().
Diffstat (limited to 'source/blender/editors/include/UI_resources.h')
-rw-r--r--source/blender/editors/include/UI_resources.h19
1 files changed, 11 insertions, 8 deletions
diff --git a/source/blender/editors/include/UI_resources.h b/source/blender/editors/include/UI_resources.h
index e3c83291089..5c97da4ebc9 100644
--- a/source/blender/editors/include/UI_resources.h
+++ b/source/blender/editors/include/UI_resources.h
@@ -232,6 +232,10 @@ enum {
TH_PREVIEW_BACK,
TH_EDGE_CREASE,
+
+ TH_DRAWEXTRA_EDGELEN,
+ TH_DRAWEXTRA_FACEAREA,
+ TH_DRAWEXTRA_FACEANG
};
/* XXX WARNING: previous is saved in file, so do not change order! */
@@ -270,17 +274,17 @@ void UI_GetThemeColor3fv(int colorid, float *col);
void UI_GetThemeColorShade3fv(int colorid, int offset, float *col);
// get the 3 or 4 byte values
-void UI_GetThemeColor3ubv(int colorid, char *col);
-void UI_GetThemeColor4ubv(int colorid, char *col);
+void UI_GetThemeColor3ubv(int colorid, unsigned char col[3]);
+void UI_GetThemeColor4ubv(int colorid, unsigned char col[4]);
// get a theme color from specified space type
-void UI_GetThemeColorType4ubv(int colorid, int spacetype, char *col);
+void UI_GetThemeColorType4ubv(int colorid, int spacetype, char col[4]);
// blends and shades between two color pointers
-void UI_ColorPtrBlendShade3ubv(char *cp1, char *cp2, float fac, int offset);
+void UI_ColorPtrBlendShade3ubv(const unsigned char cp1[3], const unsigned char cp2[3], float fac, int offset);
// get a 3 byte color, blended and shaded between two other char color pointers
-void UI_GetColorPtrBlendShade3ubv(char *cp1, char *cp2, char *col, float fac, int offset);
+void UI_GetColorPtrBlendShade3ubv(const unsigned char cp1[3], const unsigned char cp2[3], unsigned char col[3], float fac, int offset);
// clear the openGL ClearColor using the input colorid
void UI_ThemeClearColor(int colorid);
@@ -289,9 +293,8 @@ void UI_ThemeClearColor(int colorid);
void UI_SetTheme(int spacetype, int regionid);
/* only for buttons in theme editor! */
-char *UI_ThemeGetColorPtr(struct bTheme *btheme, int spacetype, int colorid);
-char *UI_ThemeColorsPup(int spacetype);
+const unsigned char *UI_ThemeGetColorPtr(struct bTheme *btheme, int spacetype, int colorid);
-void UI_make_axis_color(char *src_col, char *dst_col, char axis);
+void UI_make_axis_color(const unsigned char *src_col, unsigned char *dst_col, const char axis);
#endif /* UI_ICONS_H */