Author: sanel.z
Date: 2007-06-01 09:04:19 -0400 (Fri, 01 Jun 2007)
New Revision: 5865
Log:
STR #1696 fix
Modified:
trunk/fltk/Box.h
trunk/fltk/Symbol.h
trunk/src/Button.cxx
trunk/src/CycleButton.cxx
trunk/src/Item.cxx
trunk/src/MultiImage.cxx
trunk/src/PopupMenu.cxx
trunk/src/Slider.cxx
trunk/src/Symbol.cxx
trunk/src/TabGroup.cxx
trunk/src/ThumbWheel.cxx
trunk/src/UpBox.cxx
trunk/src/default_glyph.cxx
Modified: trunk/fltk/Box.h
===================================================================
--- trunk/fltk/Box.h 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/fltk/Box.h 2007-06-01 13:04:19 UTC (rev 5865)
@@ -46,7 +46,7 @@
bool fills_rectangle() const;
bool is_frame() const;
FrameBox(const char* name, int dx,int dy,int dw,int dh, const char* pattern,
const Box* down=0)
- : Box(name),data_(pattern),down_(down) {setInset(dx,dy,-dw,-dh);}
+ : Box(name),data_(pattern),down_(down) {set_inset(dx,dy,-dw,-dh);}
};
class FL_API FlatBox : public Box {
Modified: trunk/fltk/Symbol.h
===================================================================
--- trunk/fltk/Symbol.h 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/fltk/Symbol.h 2007-06-01 13:04:19 UTC (rev 5865)
@@ -54,13 +54,14 @@
virtual void _draw(const Rectangle&) const = 0;
void draw(const Rectangle& r) const {_draw(r);}
- virtual void drawOverlay(const Rectangle&) const;
+ virtual void draw_symbol_overlay(const Rectangle&) const;
- void setInset(int x,int y,int w,int h) {inset_.set(x,y,w,h);}
- void setInset(int x,int y) {inset_.set(x,y,-2*x,-2*y);}
- void setInset(int x) {inset_.set(x,x,-2*x,-2*x);}
- void setInset(const Rectangle& r) {inset_ = r;}
- const Rectangle& getInset() const {return inset_;}
+ void set_inset(int x,int y,int w,int h) {inset_.set(x,y,w,h);}
+ void set_inset(int x,int y) {inset_.set(x,y,-2*x,-2*y);}
+ void set_inset(int x) {inset_.set(x,x,-2*x,-2*x);}
+ void set_inset(const Rectangle& r) {inset_ = r;}
+ const Rectangle& get_inset() const {return inset_;}
+
int dx() const {return inset_.x();}
int dy() const {return inset_.y();}
int dw() const {return -inset_.w();} // inverted for back-compatability
Modified: trunk/src/Button.cxx
===================================================================
--- trunk/src/Button.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/Button.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -230,7 +230,7 @@
} else {
this->draw_label(r1, box_flags);
}
- box->drawOverlay(r);
+ box->draw_symbol_overlay(r);
}
void Button::draw() {
Modified: trunk/src/CycleButton.cxx
===================================================================
--- trunk/src/CycleButton.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/CycleButton.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -115,7 +115,7 @@
}
drawstyle(&style,flags);
- box->drawOverlay(r);
+ box->draw_symbol_overlay(r);
}
static bool try_item(CycleButton* choice, int i) {
Modified: trunk/src/Item.cxx
===================================================================
--- trunk/src/Item.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/Item.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -152,7 +152,7 @@
r1.move_x(gw+3);
}
draw_label(r1, flags());
- box->drawOverlay(r);
+ box->draw_symbol_overlay(r);
}
/** Measure the space the draw() will take and set w() and h().
@@ -240,7 +240,7 @@
box->draw(r);
Rectangle r1(r); box->inset(r1);
draw_label(r1, flags());
- box->drawOverlay(r);
+ box->draw_symbol_overlay(r);
}
void ItemGroup::layout() {
Modified: trunk/src/MultiImage.cxx
===================================================================
--- trunk/src/MultiImage.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/MultiImage.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -82,7 +82,7 @@
void MultiImage::add(Flags flags, const Symbol& image) {
if (!flags) {
image0 = ℑ
- setInset(image.getInset());
+ set_inset(image.get_inset());
// release(); // this would be consistent with documentation?
return;
}
@@ -130,7 +130,7 @@
/*! Innards of the inline constructors. */
void MultiImage::set(unsigned count, const Symbol* img0, ...) {
image0 = img0;
- setInset(img0->getInset());
+ set_inset(img0->get_inset());
n_images = count>0 ? count-1 : 0; // don't authorize setting 2^32-1 images
count on 32bit systems
if (count > 1) {
pairs = new MultiImagePair[n_images];
Modified: trunk/src/PopupMenu.cxx
===================================================================
--- trunk/src/PopupMenu.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/PopupMenu.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -84,7 +84,7 @@
// draw the little mark at the right:
// int w1 = int(textsize());
// draw_glyph(GLYPH_DOWN, x+w-w1, y, w1, h, flags);
- box->drawOverlay(r);
+ box->draw_symbol_overlay(r);
}
/*! Wrapper for Menu::popup(). For NORMAL PopupMenu this places the
Modified: trunk/src/Slider.cxx
===================================================================
--- trunk/src/Slider.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/Slider.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -317,7 +317,7 @@
// draw the focus indicator inside the box:
drawstyle(style(),flags);
- box->drawOverlay(r);
+ box->draw_symbol_overlay(r);
}
/*!
Modified: trunk/src/Symbol.cxx
===================================================================
--- trunk/src/Symbol.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/Symbol.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -326,7 +326,7 @@
define the interior area where the widget can draw it's contents.
The default version adds the value of the inset() rectangle
- (and thus if setInset() was not called it does nothing).
+ (and thus if set_inset() was not called it does nothing).
The most recent values sent to fltk::setcolor(),
fltk::setbgcolor(), fltk::setdrawflags(), fltk::setfont(), etc,
@@ -339,7 +339,7 @@
r.move_b(inset_.h());
}
-/** \fn void Symbol::setInset(const Rectangle&)
+/** \fn void Symbol::set_inset(const Rectangle&)
Set the inset rectangle. This is normally done by the constructor
for a subclass. If the inset() method is not overridden, the
values in this rectangle define the edges.
Modified: trunk/src/TabGroup.cxx
===================================================================
--- trunk/src/TabGroup.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/TabGroup.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -472,7 +472,7 @@
drawstyle(o->style(), sel && focused() ? FOCUSED|OUTPUT : OUTPUT);
setcolor(sel ? selection_textcolor() : o->textcolor());
o->draw_label(r, ALIGN_CENTER);
- FLAT_BOX->drawOverlay(r);
+ FLAT_BOX->draw_symbol_overlay(r);
}
}
Modified: trunk/src/ThumbWheel.cxx
===================================================================
--- trunk/src/ThumbWheel.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/ThumbWheel.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -168,7 +168,7 @@
}
}
setcolor(fg);
- box()->drawOverlay(Rectangle(w(),h()));
+ box()->draw_symbol_overlay(Rectangle(w(),h()));
}
ThumbWheel::ThumbWheel(int X,int Y,int W,int H,const char* L) :
Valuator(X,Y,W,H,L) {
Modified: trunk/src/UpBox.cxx
===================================================================
--- trunk/src/UpBox.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/UpBox.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -139,7 +139,7 @@
The default version draws a dotted line around the edge, using
a system-specific XOR mode, if the FOCUSED flag is on in drawflags().
*/
-void Symbol::drawOverlay(const Rectangle& r1) const {
+void Symbol::draw_symbol_overlay(const Rectangle& r1) const {
if (!drawflags(FOCUSED)) return;
fltk::Rectangle r(r1);
inset(r);
@@ -336,7 +336,7 @@
{
strokerect(r);
}
- BorderFrame(const char* n) : Box(n) {setInset(1);}
+ BorderFrame(const char* n) : Box(n) {set_inset(1);}
};
static BorderFrame borderFrame("border_frame");
/*!
@@ -364,7 +364,7 @@
bool HighlightBox::is_frame() const {return false;}
HighlightBox::HighlightBox(const char* n, const Box* b)
- : FlatBox(n), down_(b) {setInset(down_->getInset());}
+ : FlatBox(n), down_(b) {set_inset(down_->get_inset());}
static HighlightBox highlightUpBox("highlight_up", THIN_UP_BOX);
/*!
Modified: trunk/src/default_glyph.cxx
===================================================================
--- trunk/src/default_glyph.cxx 2007-05-31 14:27:07 UTC (rev 5864)
+++ trunk/src/default_glyph.cxx 2007-06-01 13:04:19 UTC (rev 5865)
@@ -111,7 +111,7 @@
if (i) {i = 0; setcolor(saved_color);}
else break;
}
- if (box) box->drawOverlay(rr);
+ if (box) box->draw_symbol_overlay(rr);
}
/**
_______________________________________________
fltk-commit mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-commit