aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorinmarket <andrewh@inmarket.com.au>2013-07-29 16:31:54 +1000
committerinmarket <andrewh@inmarket.com.au>2013-07-29 16:31:54 +1000
commit7f15192fe8a4fea1ff9cdd031aebf4001c523cbb (patch)
treed310f76823750968b9f4024f517cebbfb015a335 /include
parent7c303eb72efe8a61383c4914fb940024236b2bdb (diff)
downloaduGFX-7f15192fe8a4fea1ff9cdd031aebf4001c523cbb.tar.gz
uGFX-7f15192fe8a4fea1ff9cdd031aebf4001c523cbb.tar.bz2
uGFX-7f15192fe8a4fea1ff9cdd031aebf4001c523cbb.zip
Fix rule handling to help the end user get things right.
Tidied up anti-alias where the hardware does not support pixel read-back.
Diffstat (limited to 'include')
-rw-r--r--include/gfx_rules.h24
1 files changed, 23 insertions, 1 deletions
diff --git a/include/gfx_rules.h b/include/gfx_rules.h
index 32a6ca87..375c043f 100644
--- a/include/gfx_rules.h
+++ b/include/gfx_rules.h
@@ -139,13 +139,35 @@
#endif
#if GDISP_NEED_ASYNC && !(GFX_USE_GQUEUE && GQUEUE_NEED_GSYNC)
#if GFX_DISPLAY_RULE_WARNINGS
- #warning "GDISP: GFX_USE_GQUEUE or GQUEUE_NEED_GSYNC is not TRUE. It has been turned on for you."
+ #warning "GDISP: GDISP_NEED_ASYNC requires GFX_USE_GQUEUE and GQUEUE_NEED_GSYNC. They have been turned on for you."
#endif
#undef GFX_USE_GQUEUE
#define GFX_USE_GQUEUE TRUE
#undef GQUEUE_NEED_GSYNC
#define GQUEUE_NEED_GSYNC TRUE
#endif
+ #if GDISP_NEED_ANTIALIAS && !GDISP_NEED_PIXELREAD
+ #if GDISP_HARDWARE_PIXELREAD
+ #if GFX_DISPLAY_RULE_WARNINGS
+ #warning "GDISP: GDISP_NEED_ANTIALIAS has been set but GDISP_NEED_PIXELREAD has not. It has been turned on for you."
+ #endif
+ #undef GDISP_NEED_PIXELREAD
+ #define GDISP_NEED_PIXELREAD TRUE
+ #else
+ #if GFX_DISPLAY_RULE_WARNINGS
+ #warning "GDISP: GDISP_NEED_ANTIALIAS has been set but your hardware does not support reading back pixels. Anti-aliasing will only occur for filled characters."
+ #endif
+ #endif
+ #endif
+ #if (defined(GDISP_INCLUDE_FONT_SMALL) && GDISP_INCLUDE_FONT_SMALL) || (defined(GDISP_INCLUDE_FONT_LARGER) && GDISP_INCLUDE_FONT_LARGER) \
+ || (defined(GDISP_INCLUDE_FONT_UI1) && GDISP_INCLUDE_FONT_UI1) || (defined(GDISP_INCLUDE_FONT_UI2) && GDISP_INCLUDE_FONT_UI2)
+ #if GFX_DISPLAY_RULE_WARNINGS
+ #warning "GDISP: An old font (Small, Larger, UI1, UI2) has been defined. A single default font of DEJAVUSANS12 has been added instead."
+ #warning "GDISP: Please see <$(GFXLIB)/include/gdisp/fonts/fonts.h> for a list of available font names."
+ #endif
+ #undef GDISP_INCLUDE_FONT_DEJAVUSANS12
+ #define GDISP_INCLUDE_FONT_DEJAVUSANS12 TRUE
+ #endif
#endif
#if GFX_USE_TDISP