]> git.lyx.org Git - lyx.git/blobdiff - src/WorkArea.C
More ascii-export fixes and when making copy of single tabular cells now the
[lyx.git] / src / WorkArea.C
index a6fc52ddb00c126d25551c5d4c823ec9cf4570a9..f969ff3cf35a943b2f3f17fed3f4c056a0b1d16a 100644 (file)
@@ -9,33 +9,33 @@
  * ====================================================== */
 
 #include <config.h>
-#include <cmath>
-#include <cctype>
+
 #ifdef __GNUG__
 #pragma implementation
 #endif
 
 #include "WorkArea.h"
 #include "debug.h"
-#include "support/lstrings.h"
 #include "LyXView.h"
-#include "support/filetools.h" // LibFileSearch
 #include "lyxrc.h" // lyxrc.show_banner
 #include "version.h" // lyx_version
-#include "support/LAssert.h"
 
 #if FL_REVISION < 89 || (FL_REVISION == 89 && FL_FIXLEVEL < 5)
 #include "lyxlookup.h"
 #endif
 
+#include "support/filetools.h" // LibFileSearch
+#include "support/lstrings.h"
+#include "support/LAssert.h"
+
+#include <cmath>
+#include <cctype>
+
 using std::endl;
+using std::abs;
 
 FL_OBJECT * figinset_canvas;
 
-// needed to make the c++ compiler find the correct version of abs.
-// This is at least true for g++.
-//using std::abs;
-
 namespace {
 
 inline
@@ -80,7 +80,7 @@ WorkArea::WorkArea(int xpos, int ypos, int width, int height)
                       << width << 'x' << height << endl;
        //
        FL_OBJECT * obj;
-       int const bw = int(std::abs(float(fl_get_border_width())));
+       int const bw = int(abs(fl_get_border_width()));
 
        // We really want to get rid of figinset_canvas.
        ::figinset_canvas = figinset_canvas = obj =
@@ -202,7 +202,7 @@ void WorkArea::resize(int xpos, int ypos, int width, int height)
 {
        fl_freeze_all_forms();
        
-       int const bw = int(std::abs(float(fl_get_border_width())));
+       int const bw = int(abs(fl_get_border_width()));
 
        // a box
        fl_set_object_geometry(backgroundbox, xpos, ypos, width - 15, height);
@@ -325,8 +325,6 @@ void WorkArea::scroll_cb(FL_OBJECT * ob, long)
 }
 
 
-bool Lgb_bug_find_hack = false;
-
 int WorkArea::work_area_handler(FL_OBJECT * ob, int event,
                                FL_Coord, FL_Coord ,
                                int key, void * xev)
@@ -347,9 +345,7 @@ int WorkArea::work_area_handler(FL_OBJECT * ob, int event,
                        return 1;
                lyxerr[Debug::WORKAREA] << "Workarea event: DRAW" << endl;
                area->createPixmap(area->workWidth(), area->height());
-               Lgb_bug_find_hack = true;
                area->workAreaExpose();
-               Lgb_bug_find_hack = false;
                break;
        case FL_PUSH:
                if (!ev || ev->xbutton.button == 0) break;