Skip to content

Commit 9b09bf5

Browse files
authored
Merge pull request #3 from tinycorelinux/mike_rescaling
juanito: merge MikeL work for fltk-1.4
2 parents 0235344 + 85f8ea4 commit 9b09bf5

File tree

8 files changed

+222
-647
lines changed

8 files changed

+222
-647
lines changed

Frame.C

Lines changed: 175 additions & 152 deletions
Large diffs are not rendered by default.

Frame.H

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -102,10 +102,10 @@ class Frame : public Fl_Window {
102102
Desktop* desktop_;
103103

104104
FrameButton close_button;
105-
FrameButton iconize_button;
106-
FrameButton max_h_button;
107105
FrameButton max_w_button;
108106
FrameButton min_w_button;
107+
FrameButton max_h_button;
108+
FrameButton iconize_button;
109109

110110
int maximize_width();
111111
int maximize_height();

Hotkeys.C

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -225,7 +225,7 @@ static void GrowShorter(void) { // Ctrl+Alt+PageDn
225225
GrowFrame(0, -1);
226226
}
227227

228-
static void ToggleVertMax(void) {// Ctrl+Alt+V
228+
void ToggleVertMax(void) {// Ctrl+Alt+V
229229
static int nonmax_h = Fl::h() - 64;
230230
static int nonmax_y = 32;
231231
Frame* f = Frame::activeFrame();
@@ -240,7 +240,7 @@ static void ToggleVertMax(void) {// Ctrl+Alt+V
240240
}
241241
}
242242

243-
static void ToggleHorzMax(void) {// Ctrl+Alt+H
243+
void ToggleHorzMax(void) {// Ctrl+Alt+H
244244
static int nonmax_w = Fl::w() - 64;
245245
static int nonmax_x = 32;
246246
Frame* f = Frame::activeFrame();

Menu.C

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ frame_label_draw(const Fl_Label* o, int X, int Y, int W, int H, Fl_Align align)
8888
fl_rectf(X+x+SCREEN_DX, Y+y+SCREEN_DX, w, h);
8989
}
9090
}
91-
fl_font(o->font, o->size);
91+
fl_font(o->font, TitleFontSz); // o->size);
9292
fl_color((Fl_Color)o->color);
9393
const char* l = f->label(); if (!l) l = "unnamed";
9494
// double any ampersands to turn off the underscores:
@@ -111,7 +111,7 @@ frame_label_measure(const Fl_Label* o, int& W, int& H)
111111
Frame* f = (Frame*)(o->value);
112112
if (window_deleted(f)) {W = MENU_ICON_W+3; H = MENU_ICON_H; return;}
113113
const char* l = f->label(); if (!l) l = "unnamed";
114-
fl_font(o->font, o->size);
114+
fl_font(o->font, TitleFontSz); // o->size);
115115
fl_measure(l, W, H);
116116
W += MENU_ICON_W+3;
117117
if (W > MAX_MENU_WIDTH) W = MAX_MENU_WIDTH;
@@ -124,15 +124,15 @@ frame_label_measure(const Fl_Label* o, int& W, int& H)
124124
static void
125125
label_draw(const Fl_Label* o, int X, int Y, int W, int H, Fl_Align align)
126126
{
127-
fl_font(o->font, o->size);
127+
fl_font(o->font, TitleFontSz); // o->size);
128128
fl_color((Fl_Color)o->color);
129129
fl_draw(o->value, X+MENU_ICON_W+3, Y, W-MENU_ICON_W-3, H, align);
130130
}
131131

132132
static void
133133
label_measure(const Fl_Label* o, int& W, int& H)
134134
{
135-
fl_font(o->font, o->size);
135+
fl_font(o->font, TitleFontSz); // o->size);
136136
fl_measure(o->value, W, H);
137137
W += MENU_ICON_W+3;
138138
if (W > MAX_MENU_WIDTH) W = MAX_MENU_WIDTH;
@@ -289,7 +289,7 @@ init(Fl_Menu_Item& m, const char* data)
289289
m.labeltype(FL_NORMAL_LABEL);
290290
m.shortcut(0);
291291
m.labelfont(MENU_FONT_SLOT);
292-
m.labelsize(MENU_FONT_SIZE);
292+
m.labelsize(TitleFontSz); // MENU_FONT_SIZE);
293293
m.labelcolor(FL_FOREGROUND_COLOR);
294294
}
295295

0 commit comments

Comments
 (0)