summaryrefslogtreecommitdiff
path: root/test/flex_login.cxx
diff options
context:
space:
mode:
authorAlbrecht Schlosser <albrechts.fltk@online.de>2022-12-15 16:46:40 +0100
committerGitHub <noreply@github.com>2022-12-15 16:46:40 +0100
commit44a2547394a3b4f8b0177c2f33aa8ed47a2c1051 (patch)
treed0611bedf1be051c9e5b2183314bc7e17648c5ad /test/flex_login.cxx
parent2fd1866f492daa4caa7fdad6c05cd34bc79ba913 (diff)
Rename some Fl_Flex methods for FLTK compliance (#594)
Change some method names to comply with FLTK style as discussed in fltk.coredev, thread "Fl_Flex method name question". * Rename Fl_Flex::margins(...) to Fl_Flex::margin(...) (use singular form for all margin related methods) * Remove Fl_Flex::setSize() and isSetSize() "backwards compatibility" methods * Rename Fl_Flex::set_size(...) to fixed(...) Note: the latter affects existing (pre-release) fluid (.fl) files: you may want to edit and replace "set_size_tuples" with "fixed_size_tuples"
Diffstat (limited to 'test/flex_login.cxx')
-rw-r--r--test/flex_login.cxx28
1 files changed, 14 insertions, 14 deletions
diff --git a/test/flex_login.cxx b/test/flex_login.cxx
index e8098cbce..be72e6c8b 100644
--- a/test/flex_login.cxx
+++ b/test/flex_login.cxx
@@ -40,7 +40,7 @@ void buttons_panel(Fl_Flex *parent) {
b->align(FL_ALIGN_INSIDE | FL_ALIGN_RIGHT);
Fl_Input *username = new Fl_Input(0, 0, 0, 0, "");
- urow->set_size(username, 180);
+ urow->fixed(username, 180);
urow->end();
}
@@ -50,7 +50,7 @@ void buttons_panel(Fl_Flex *parent) {
b->align(FL_ALIGN_INSIDE | FL_ALIGN_RIGHT);
Fl_Input *password = new Fl_Input(0, 0, 0, 0, "");
- prow->set_size(password, 180);
+ prow->fixed(password, 180);
prow->end();
}
@@ -62,8 +62,8 @@ void buttons_panel(Fl_Flex *parent) {
Fl_Button *reg = create_button("Register");
Fl_Button *login = create_button("Login");
- brow->set_size(reg, 80);
- brow->set_size(login, 80);
+ brow->fixed(reg, 80);
+ brow->fixed(login, 80);
brow->gap(20);
brow->end();
@@ -71,12 +71,12 @@ void buttons_panel(Fl_Flex *parent) {
Fl_Box *b = new Fl_Box(0, 0, 0, 0, "");
- parent->set_size(w, 60);
- parent->set_size(urow, 30);
- parent->set_size(prow, 30);
- parent->set_size(pad, 1);
- parent->set_size(brow, 30);
- parent->set_size(b, 30);
+ parent->fixed(w, 60);
+ parent->fixed(urow, 30);
+ parent->fixed(prow, 30);
+ parent->fixed(pad, 1);
+ parent->fixed(brow, 30);
+ parent->fixed(b, 30);
}
// create widgets inside a row, i.e. parent is type(ROW)
@@ -95,9 +95,9 @@ void middle_panel(Fl_Flex *parent) {
new Fl_Box(0, 0, 0, 0, "");
- parent->set_size(box, 200);
- parent->set_size(spacer, 10);
- parent->set_size(bp, 300);
+ parent->fixed(box, 200);
+ parent->fixed(spacer, 10);
+ parent->fixed(bp, 300);
}
// The main panel consists of three "rows" inside a column, i.e. parent is
@@ -114,7 +114,7 @@ void mainPanel(Fl_Flex *parent) {
new Fl_Box(0, 0, 0, 0, ""); // flexible separator
- parent->set_size(mp, 200);
+ parent->fixed(mp, 200);
}
int main(int argc, char **argv) {