Mercurial > foo_out_sdl
comparison foosdk/sdk/libPPUI/PaintUtils.h @ 1:20d02a178406 default tip
*: check in everything else
yay
| author | Paper <paper@tflc.us> |
|---|---|
| date | Mon, 05 Jan 2026 02:15:46 -0500 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| 0:e9bb126753e7 | 1:20d02a178406 |
|---|---|
| 1 #pragma once | |
| 2 | |
| 3 #include <Uxtheme.h> | |
| 4 | |
| 5 namespace PaintUtils { | |
| 6 t_uint32 BlendColor(t_uint32 p_color1, t_uint32 p_color2, int p_percentage = 50) throw(); | |
| 7 t_uint32 BlendColorEx(t_uint32 p_color1, t_uint32 p_color2, double mix = 0.5) throw(); | |
| 8 t_uint32 DriftColor(t_uint32 p_color,unsigned p_delta,bool p_direction) throw(); | |
| 9 void FillVertexColor(TRIVERTEX & p_vertex,t_uint32 p_color,t_uint16 p_alpha = 0) throw(); | |
| 10 void FillRectSimple(CDCHandle p_dc,const CRect & p_rect,t_uint32 p_color) throw(); | |
| 11 void GradientFillRect(CDCHandle p_dc,const CRect & p_rect,t_uint32 p_color1, t_uint32 p_color2, bool p_horizontal) throw(); | |
| 12 void GradientSplitRect(CDCHandle p_dc,const CRect & p_rect,t_uint32 p_bkColor, t_uint32 p_gradientColor,int p_splitPercent) throw(); | |
| 13 void GradientBar(CDCHandle p_dc,const CRect & p_rect,t_uint32 p_exterior, t_uint32 p_interior, int p_percentage) throw(); | |
| 14 void RenderItemBackground(CDCHandle p_dc,const CRect & p_itemRect,t_size p_item,t_uint32 p_color) throw(); | |
| 15 | |
| 16 t_uint32 DetermineTextColor(t_uint32 background) throw(); | |
| 17 double Luminance(t_uint32 color) throw(); | |
| 18 | |
| 19 void AddRectToRgn(HRGN rgn, CRect const & rect) throw(); | |
| 20 | |
| 21 void FocusRect(CDCHandle dc, CRect const & rect) throw(); | |
| 22 void FocusRect2(CDCHandle dc, CRect const & rect, COLORREF bkColor) throw(); | |
| 23 | |
| 24 namespace TrackBar { | |
| 25 void DrawThumb(HTHEME theme,HDC dc,int state,const RECT * rcThumb, const RECT * rcUpdate); | |
| 26 void DrawTrack(HTHEME theme,HDC dc,const RECT * rcTrack, const RECT * rcUpdate); | |
| 27 void DrawTrack2(HDC dc, const CRect& rcTrack, const CRect& rcUpdate, COLORREF highlight, COLORREF shadow); | |
| 28 void DrawTrackVolume(HTHEME theme,HDC dc,const CRect & rcTrack, const CRect & rcUpdate); | |
| 29 void DrawTrackVolume2(HDC dc, const CRect& rcTrack, const CRect& rcUpdate, COLORREF highlight, COLORREF shadow); | |
| 30 }; | |
| 31 | |
| 32 void DrawSmoothedLine(HDC dc, CPoint p1, CPoint p2, COLORREF col, double width); | |
| 33 | |
| 34 enum { | |
| 35 TextOutColors_Dim = 21, | |
| 36 TextOutColors_Highlight = 22, | |
| 37 }; | |
| 38 void TextOutColors(HDC dc,const TCHAR * src,int len,CPoint offset,const CRect & clip,const t_uint32 colors[3], int tabWidthTotal = 0, int tabWidthDiv = 1); | |
| 39 void TextOutColorsEx(HDC dc,const TCHAR * src,const CRect & target,DWORD flags,const t_uint32 colors[3]); | |
| 40 void TextOutColors_StripCodesAppend(pfc::string_formatter & out, const char * in); | |
| 41 void TextOutColors_StripCodes(pfc::string_formatter & out, const char * in); | |
| 42 | |
| 43 t_uint32 TextOutColors_CalcWidth(HDC dc, const TCHAR * src); | |
| 44 CSize TextOutColors_CalcSize(HDC dc, const TCHAR * src); | |
| 45 | |
| 46 pfc::string TextOutColors_ImportScript(pfc::string script); | |
| 47 void TextOutColors_ImportScript(pfc::string_base & out, const char * in); | |
| 48 | |
| 49 bool TextContainsCodes(const TCHAR * src); | |
| 50 | |
| 51 t_uint32 DrawText_TranslateHeaderAlignment(t_uint32 val); | |
| 52 | |
| 53 void RenderButton(HWND wnd_, HDC dc_, CRect rcUpdate, bool bPressed); | |
| 54 void PaintSeparatorControl(HWND wnd_); | |
| 55 } |
