]> Shamusworld >> Repos - apple2/blobdiff - src/gui/guimisc.h
Fixed misc. bugs preventing certain games from working, added pause mode.
[apple2] / src / gui / guimisc.h
index 6382cc9c49186a292a91dcb8364412d0f2166efa..30f30238f46a243e7486dd8035c8bbee7de6a94b 100755 (executable)
@@ -9,16 +9,16 @@
 
 #include <SDL.h>
 #include <stdarg.h>
-#include "types.h"
+#include <stdint.h>
 
 // Useful structs
 
 struct Font
 {
-       Font(uint8 * d = NULL, uint32 w = 0, uint32 h = 0): data(d), width(w), height(h) {}
+       Font(uint8_t * d = NULL, uint32_t w = 0, uint32_t h = 0): data(d), width(w), height(h) {}
 
-       uint8 * data;
-       uint32 width, height;
+       uint8_t * data;
+       uint32_t width, height;
 };
 
 // Okay, this is ugly but works and I can't think of any better way to handle this. So what
@@ -40,21 +40,23 @@ struct Font
 
 // Global functions
 
-//void SetFont(uint8 *, uint32, uint32);
+//void SetFont(uint8_t *, uint32_t, uint32_t);
 void SetNewFont(Font);
 void RestoreOldFont(void);
-uint32 GetFontWidth(void);
-uint32 GetFontHeight(void);
-void DrawStringTrans(SDL_Surface * screen, uint32 x, uint32 y, uint32 color, const char * text, ...);
-void DrawStringOpaque(SDL_Surface * screen, uint32 x, uint32 y, uint32 fg, uint32 bg, const char * text, ...);
+uint32_t GetFontWidth(void);
+uint32_t GetFontHeight(void);
+void DrawStringTrans(SDL_Surface * screen, uint32_t x, uint32_t y, uint32_t color, const char * text, ...);
+void DrawStringOpaque(SDL_Surface * screen, uint32_t x, uint32_t y, uint32_t fg, uint32_t bg, const char * text, ...);
 
-void DrawStringOpaqueSmall(SDL_Surface * screen, uint32 x, uint32 y, uint32 fg, uint32 bg, const char * text, ...);
+//Not sure these belong here, but there you go...
+bool RectanglesIntersect(SDL_Rect r1, SDL_Rect r2);
+bool RectangleFirstInsideSecond(SDL_Rect r1, SDL_Rect r2);
 
 // GUI bitmaps (exported)
 
-extern uint8 closeBox[];
-extern uint8 closeBoxDown[];
-extern uint8 closeBoxHover[];
-extern uint8 floppyDiskImg[];
+extern uint8_t closeBox[];
+extern uint8_t closeBoxDown[];
+extern uint8_t closeBoxHover[];
+extern uint8_t floppyDiskImg[];
 
 #endif // __GUIMISC_H__