53 static bool g_isSelectionLocked = false; |
53 static bool g_isSelectionLocked = false; |
54 |
54 |
55 cfg (Bool, lv_colorize, true); |
55 cfg (Bool, lv_colorize, true); |
56 cfg (String, gui_colortoolbar, "16:24:|:1:2:4:14:0:15:|:33:34:36:46"); |
56 cfg (String, gui_colortoolbar, "16:24:|:1:2:4:14:0:15:|:33:34:36:46"); |
57 cfg (Bool, gui_implicitfiles, false); |
57 cfg (Bool, gui_implicitfiles, false); |
58 extern_cfg (List, io_recentfiles); |
58 extern_cfg (List, io_recentfiles); |
59 extern_cfg (Bool, gl_axes); |
59 extern_cfg (Bool, gl_axes); |
60 extern_cfg (String, gl_maincolor); |
60 extern_cfg (String, gl_maincolor); |
61 extern_cfg (Float, gl_maincolor_alpha); |
61 extern_cfg (Float, gl_maincolor_alpha); |
62 extern_cfg (Bool, gl_wireframe); |
62 extern_cfg (Bool, gl_wireframe); |
63 extern_cfg (Bool, gl_colorbfc); |
63 extern_cfg (Bool, gl_colorbfc); |
|
64 extern_cfg (Bool, gl_drawangles); |
64 |
65 |
65 #define act(N) extern_cfg (KeySequence, key_##N); |
66 #define act(N) extern_cfg (KeySequence, key_##N); |
66 #include "actions.h" |
67 #include "actions.h" |
67 |
68 |
68 // ============================================================================= |
69 // ============================================================================= |
927 int pos = his->getPosition(); |
928 int pos = his->getPosition(); |
928 ui->actionUndo->setEnabled (pos != -1); |
929 ui->actionUndo->setEnabled (pos != -1); |
929 ui->actionRedo->setEnabled (pos < (long) his->getSize() - 1); |
930 ui->actionRedo->setEnabled (pos < (long) his->getSize() - 1); |
930 ui->actionAxes->setChecked (gl_axes); |
931 ui->actionAxes->setChecked (gl_axes); |
931 ui->actionBFCView->setChecked (gl_colorbfc); |
932 ui->actionBFCView->setChecked (gl_colorbfc); |
|
933 ui->actionDrawAngles->setChecked (gl_drawangles); |
932 } |
934 } |
933 |
935 |
934 QImage imageFromScreencap (uchar* data, int w, int h) |
936 QImage imageFromScreencap (uchar* data, int w, int h) |
935 { // GL and Qt formats have R and B swapped. Also, GL flips Y - correct it as well. |
937 { // GL and Qt formats have R and B swapped. Also, GL flips Y - correct it as well. |
936 return QImage (data, w, h, QImage::Format_ARGB32).rgbSwapped().mirrored(); |
938 return QImage (data, w, h, QImage::Format_ARGB32).rgbSwapped().mirrored(); |