Remove 3 pixel X border in input fields.

Don't quote chars 0x80 to 0x9f in input fields (labels didn't...)


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2541 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Michael R Sweet 2002-07-20 05:56:44 +00:00
parent 66f06dae9e
commit 667eb3ef6c
4 changed files with 18 additions and 28 deletions

View File

@ -1,5 +1,8 @@
CHANGES IN FLTK 1.1.0
- Removed extra 3 pixel border around input fields.
- No longer quote characters from 0x80 to 0x9f in input
fields.
- Improved speed of Fl_Browser_::display() method with
large lists (patch from Stephen Davies.)
- Fl_Help_View didn't properly handle NULL from the link

View File

@ -1,5 +1,5 @@
//
// "$Id: Fl_Input.cxx,v 1.10.2.15.2.11 2002/05/14 15:24:03 spitzak Exp $"
// "$Id: Fl_Input.cxx,v 1.10.2.15.2.12 2002/07/20 05:56:44 easysw Exp $"
//
// Input widget for the Fast Light Tool Kit (FLTK).
//
@ -39,8 +39,8 @@ void Fl_Input::draw() {
if (input_type() == FL_HIDDEN_INPUT) return;
Fl_Boxtype b = box();
if (damage() & FL_DAMAGE_ALL) draw_box(b, color());
Fl_Input_::drawtext(x()+Fl::box_dx(b)+3, y()+Fl::box_dy(b),
w()-Fl::box_dw(b)-6, h()-Fl::box_dh(b));
Fl_Input_::drawtext(x()+Fl::box_dx(b), y()+Fl::box_dy(b),
w()-Fl::box_dw(b), h()-Fl::box_dh(b));
}
// kludge so shift causes selection to extend:
@ -291,8 +291,8 @@ int Fl_Input::handle(int event) {
int oldpos = position(), oldmark = mark();
Fl_Boxtype b = box();
Fl_Input_::handle_mouse(
x()+Fl::box_dx(b)+3, y()+Fl::box_dy(b),
w()-Fl::box_dw(b)-6, h()-Fl::box_dh(b), 0);
x()+Fl::box_dx(b), y()+Fl::box_dy(b),
w()-Fl::box_dw(b), h()-Fl::box_dh(b), 0);
newpos = position();
position( oldpos, oldmark );
if (Fl::focus()==this && !Fl::event_state(FL_SHIFT) && input_type()!=FL_SECRET_INPUT &&
@ -361,8 +361,8 @@ int Fl_Input::handle(int event) {
{
Fl_Boxtype b = box();
Fl_Input_::handle_mouse(
x()+Fl::box_dx(b)+3, y()+Fl::box_dy(b),
w()-Fl::box_dw(b)-6, h()-Fl::box_dh(b), 0);
x()+Fl::box_dx(b), y()+Fl::box_dy(b),
w()-Fl::box_dw(b), h()-Fl::box_dh(b), 0);
}
return 1;
@ -384,8 +384,8 @@ int Fl_Input::handle(int event) {
}
Fl_Boxtype b = box();
return Fl_Input_::handletext(event,
x()+Fl::box_dx(b)+3, y()+Fl::box_dy(b),
w()-Fl::box_dw(b)-6, h()-Fl::box_dh(b));
x()+Fl::box_dx(b), y()+Fl::box_dy(b),
w()-Fl::box_dw(b), h()-Fl::box_dh(b));
}
Fl_Input::Fl_Input(int x, int y, int w, int h, const char *l)
@ -393,5 +393,5 @@ Fl_Input::Fl_Input(int x, int y, int w, int h, const char *l)
}
//
// End of "$Id: Fl_Input.cxx,v 1.10.2.15.2.11 2002/05/14 15:24:03 spitzak Exp $".
// End of "$Id: Fl_Input.cxx,v 1.10.2.15.2.12 2002/07/20 05:56:44 easysw Exp $".
//

View File

@ -1,5 +1,5 @@
//
// "$Id: Fl_Input_.cxx,v 1.21.2.11.2.12 2002/04/27 19:20:50 easysw Exp $"
// "$Id: Fl_Input_.cxx,v 1.21.2.11.2.13 2002/07/20 05:56:44 easysw Exp $"
//
// Common input widget routines for the Fast Light Tool Kit (FLTK).
//
@ -87,15 +87,6 @@ const char* Fl_Input_::expand(const char* p, char* buf) const {
*o++ = '^';
*o++ = c ^ 0x40;
}
#ifdef __APPLE__
} else if ( 0 ) { // this is a rather complex issue on MacOS: see glyphs vs. characters in font sets...
#else
} else if (c >= 128 && c < 0xA0) {
#endif
*o++ = '\\';
*o++ = (c>>6)+'0';
*o++ = ((c>>3)&7)+'0';
*o++ = (c&7)+'0';
} else if (c == 0xA0) { // nbsp
*o++ = ' ';
} else {
@ -146,12 +137,8 @@ void Fl_Input_::minimal_update(int p) {
mu_p = p;
}
//#if defined(__APPLE__) || USE_XFT
// redraw();
//#else
damage(FL_DAMAGE_EXPOSE);
erase_cursor_only = 0;
//#endif // __APPLE__ || USE_XFT
}
void Fl_Input_::minimal_update(int p, int q) {
@ -885,5 +872,5 @@ Fl_Input_::~Fl_Input_() {
}
//
// End of "$Id: Fl_Input_.cxx,v 1.21.2.11.2.12 2002/04/27 19:20:50 easysw Exp $".
// End of "$Id: Fl_Input_.cxx,v 1.21.2.11.2.13 2002/07/20 05:56:44 easysw Exp $".
//

View File

@ -1,5 +1,5 @@
//
// "$Id: Fl_Value_Output.cxx,v 1.6.2.3.2.3 2002/05/12 11:12:56 easysw Exp $"
// "$Id: Fl_Value_Output.cxx,v 1.6.2.3.2.4 2002/07/20 05:56:44 easysw Exp $"
//
// Value output widget for the Fast Light Tool Kit (FLTK).
//
@ -47,7 +47,7 @@ void Fl_Value_Output::draw() {
format(buf);
fl_color(active_r() ? textcolor() : fl_inactive(textcolor()));
fl_font(textfont(), textsize());
fl_draw(buf,X+3,Y,W-6,H,FL_ALIGN_LEFT);
fl_draw(buf,X,Y,W,H,FL_ALIGN_LEFT);
}
int Fl_Value_Output::handle(int event) {
@ -97,5 +97,5 @@ Fl_Value_Output::Fl_Value_Output(int x,int y,int w,int h,const char *l)
}
//
// End of "$Id: Fl_Value_Output.cxx,v 1.6.2.3.2.3 2002/05/12 11:12:56 easysw Exp $".
// End of "$Id: Fl_Value_Output.cxx,v 1.6.2.3.2.4 2002/07/20 05:56:44 easysw Exp $".
//