Browse Source

Made Comment Properties dialog obey HIG (I hope) and fixed resizing behavior (STR #891, partial)

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@4375 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
pull/168/head
Matthias Melcher 20 years ago
parent
commit
1c4ed73d47
  1. 24
      fluid/function_panel.cxx
  2. 28
      fluid/function_panel.fl

24
fluid/function_panel.cxx

@ -362,10 +362,10 @@ Fl_Button *comment_load=(Fl_Button *)0;
Fl_Window* make_comment_panel() { Fl_Window* make_comment_panel() {
Fl_Window* w; Fl_Window* w;
{ Fl_Window* o = comment_panel = new Fl_Window(545, 285, "Comment Properties"); { Fl_Window* o = comment_panel = new Fl_Window(552, 282, "Comment Properties");
w = o; w = o;
o->labelsize(11); o->labelsize(11);
{ CodeEditor* o = comment_input = new CodeEditor(95, 10, 438, 241); { CodeEditor* o = comment_input = new CodeEditor(110, 10, 430, 230);
o->box(FL_DOWN_BOX); o->box(FL_DOWN_BOX);
o->color(FL_BACKGROUND2_COLOR); o->color(FL_BACKGROUND2_COLOR);
o->selection_color(FL_SELECTION_COLOR); o->selection_color(FL_SELECTION_COLOR);
@ -380,42 +380,42 @@ Fl_Window* make_comment_panel() {
Fl_Group::current()->resizable(o); Fl_Group::current()->resizable(o);
o->when(FL_WHEN_ENTER_KEY_CHANGED|FL_WHEN_RELEASE); o->when(FL_WHEN_ENTER_KEY_CHANGED|FL_WHEN_RELEASE);
} }
{ Fl_Group* o = new Fl_Group(368, 255, 167, 25); { Fl_Group* o = new Fl_Group(110, 250, 430, 20);
o->labelsize(11); o->labelsize(11);
{ Fl_Return_Button* o = comment_panel_ok = new Fl_Return_Button(419, 255, 55, 20, "OK"); { Fl_Return_Button* o = comment_panel_ok = new Fl_Return_Button(370, 250, 80, 20, "OK");
o->labelsize(11); o->labelsize(11);
w->hotspot(o); w->hotspot(o);
} }
{ Fl_Button* o = comment_panel_cancel = new Fl_Button(479, 255, 56, 20, "Cancel"); { Fl_Button* o = comment_panel_cancel = new Fl_Button(460, 250, 80, 20, "Cancel");
o->shortcut(0xff1b); o->shortcut(0xff1b);
o->labelsize(11); o->labelsize(11);
} }
{ Fl_Box* o = new Fl_Box(368, 255, 1, 1); { Fl_Box* o = new Fl_Box(110, 250, 250, 20);
o->labelsize(11); o->labelsize(11);
Fl_Group::current()->resizable(o); Fl_Group::current()->resizable(o);
} }
o->end(); o->end();
} }
{ Fl_Group* o = new Fl_Group(10, 10, 205, 127); { Fl_Group* o = new Fl_Group(10, 10, 90, 243);
o->labelsize(11); o->labelsize(11);
{ Fl_Light_Button* o = comment_in_source = new Fl_Light_Button(10, 10, 80, 20, "In Source"); { Fl_Light_Button* o = comment_in_source = new Fl_Light_Button(10, 10, 90, 20, "In Source");
o->tooltip("Put the comment into the source (.cxx) file."); o->tooltip("Put the comment into the source (.cxx) file.");
o->labelsize(11); o->labelsize(11);
o->when(FL_WHEN_NEVER); o->when(FL_WHEN_NEVER);
} }
{ Fl_Light_Button* o = comment_in_header = new Fl_Light_Button(10, 35, 80, 20, "In Header"); { Fl_Light_Button* o = comment_in_header = new Fl_Light_Button(10, 40, 90, 20, "In Header");
o->tooltip("Put the comment into the header (.h) file."); o->tooltip("Put the comment into the header (.h) file.");
o->labelsize(11); o->labelsize(11);
o->when(FL_WHEN_NEVER); o->when(FL_WHEN_NEVER);
} }
{ Fl_Menu_Button* o = comment_predefined = new Fl_Menu_Button(10, 60, 80, 20, "Predefined"); { Fl_Menu_Button* o = comment_predefined = new Fl_Menu_Button(10, 70, 90, 20, "Predefined");
o->labelsize(11); o->labelsize(11);
o->textsize(11); o->textsize(11);
} }
{ Fl_Button* o = comment_load = new Fl_Button(10, 85, 80, 22, "Import..."); { Fl_Button* o = comment_load = new Fl_Button(10, 100, 90, 20, "Import...");
o->labelsize(11); o->labelsize(11);
} }
{ Fl_Box* o = new Fl_Box(10, 135, 2, 2); { Fl_Box* o = new Fl_Box(10, 132, 90, 121);
o->labelsize(11); o->labelsize(11);
Fl_Group::current()->resizable(o); Fl_Group::current()->resizable(o);
} }

28
fluid/function_panel.fl

@ -215,50 +215,50 @@ Function {make_class_panel()} {open
Function {make_comment_panel()} {open Function {make_comment_panel()} {open
} { } {
Fl_Window comment_panel { Fl_Window comment_panel {
label {Comment Properties} label {Comment Properties} open selected
xywh {328 152 545 285} type Single labelsize 11 hide resizable modal xywh {422 190 552 282} type Single labelsize 11 resizable modal visible
} { } {
Fl_Text_Editor comment_input {selected Fl_Text_Editor comment_input {
xywh {95 10 438 241} box DOWN_BOX labelsize 11 textfont 4 textsize 11 resizable xywh {110 10 430 230} box DOWN_BOX labelsize 11 textfont 4 textsize 11 resizable
code0 {o->when(FL_WHEN_ENTER_KEY_CHANGED|FL_WHEN_RELEASE);} code0 {o->when(FL_WHEN_ENTER_KEY_CHANGED|FL_WHEN_RELEASE);}
class CodeEditor class CodeEditor
} }
Fl_Group {} {open Fl_Group {} {open
xywh {368 255 167 25} labelsize 11 xywh {110 250 430 20} labelsize 11
} { } {
Fl_Return_Button comment_panel_ok { Fl_Return_Button comment_panel_ok {
label OK label OK
xywh {419 255 55 20} labelsize 11 hotspot xywh {370 250 80 20} labelsize 11 hotspot
} }
Fl_Button comment_panel_cancel { Fl_Button comment_panel_cancel {
label Cancel label Cancel
xywh {479 255 56 20} shortcut 0xff1b labelsize 11 xywh {460 250 80 20} shortcut 0xff1b labelsize 11
} }
Fl_Box {} { Fl_Box {} {
xywh {368 255 1 1} labelsize 11 resizable xywh {110 250 250 20} labelsize 11 resizable
} }
} }
Fl_Group {} {open Fl_Group {} {open
xywh {10 10 205 127} labelsize 11 xywh {10 10 90 243} labelsize 11
} { } {
Fl_Light_Button comment_in_source { Fl_Light_Button comment_in_source {
label {In Source} label {In Source}
tooltip {Put the comment into the source (.cxx) file.} xywh {10 10 80 20} labelsize 11 when 0 tooltip {Put the comment into the source (.cxx) file.} xywh {10 10 90 20} labelsize 11 when 0
} }
Fl_Light_Button comment_in_header { Fl_Light_Button comment_in_header {
label {In Header} label {In Header}
tooltip {Put the comment into the header (.h) file.} xywh {10 35 80 20} labelsize 11 when 0 tooltip {Put the comment into the header (.h) file.} xywh {10 40 90 20} labelsize 11 when 0
} }
Fl_Menu_Button comment_predefined { Fl_Menu_Button comment_predefined {
label Predefined open label Predefined open
xywh {10 60 80 20} labelsize 11 textsize 11 xywh {10 70 90 20} labelsize 11 textsize 11
} {} } {}
Fl_Button comment_load { Fl_Button comment_load {
label {Import...} label {Import...}
xywh {10 85 80 22} labelsize 11 xywh {10 100 90 20} labelsize 11
} }
Fl_Box {} { Fl_Box {} {
xywh {10 135 2 2} labelsize 11 resizable xywh {10 132 90 121} labelsize 11 resizable
} }
} }
} }

Loading…
Cancel
Save