From ffad932289d17877a506a51c5f2f32c743d747d8 Mon Sep 17 00:00:00 2001 From: Fabien Costantini Date: Thu, 25 Sep 2008 18:26:33 +0000 Subject: + Cairo branch merged after successful testing on Mac OS X 10.5.4, Linux Ubuntu 8.04,Windows XPSP2. This integration is minimum as discussed, in particular it does not feature any fltk cairo drawing substitution as in fltk2. Still it provides all the fundations to go further even in next 1.4 ... By default *no* cairo features are implemented nor linked, it can only be activated by --enable-cairo whose default is false. Please visit the README.cairo for complete description. + fixed UTF8 compilation pb on linux ubuntu + minor comments fixes on the fly git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6350 ea41ed52-d2ee-0310-a9c1-e6b18d33e121 --- src/Fl_Text_Buffer.cxx | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) (limited to 'src/Fl_Text_Buffer.cxx') diff --git a/src/Fl_Text_Buffer.cxx b/src/Fl_Text_Buffer.cxx index 817217c8e..e3d07ea67 100644 --- a/src/Fl_Text_Buffer.cxx +++ b/src/Fl_Text_Buffer.cxx @@ -64,8 +64,15 @@ static char *expandTabs(const char *text, int startIndent, int tabDist, char nullSubsChar, int *newLen); static char *unexpandTabs(char *text, int startIndent, int tabDist, char nullSubsChar, int *newLen); -static int max(int i1, int i2); -static int min(int i1, int i2); +#ifndef min +static int max(int i1, int i2) { + return i1 >= i2 ? i1 : i2; +} + +static int min(int i1, int i2) { + return i1 <= i2 ? i1 : i2; +} +#endif static const char *ControlCodeTable[ 32 ] = { "nul", "soh", "stx", "etx", "eot", "enq", "ack", "bel", @@ -2569,14 +2576,6 @@ static char *unexpandTabs(char *text, int startIndent, int tabDist, return outStr; } -static int max(int i1, int i2) { - return i1 >= i2 ? i1 : i2; -} - -static int min(int i1, int i2) { - return i1 <= i2 ? i1 : i2; -} - int /** Inserts a file at the specified position. Returns 0 on success, -- cgit v1.2.3