> Is it possible to extend or shift the "sensitivity-area" of 
> the checkbox 
> in Fl_Check_Button by an easy way? We have a bit a problem with our 
> touchscreen -> we have a little offset on y-position. Because 
> of this, 
> it would be nice, if I could "shift" the sensitive area of 
> the checkbox 
> a bit...

Sure - check-buttons are always drawn pretty much the same, so the w,h
that you pass to the constructor sets the sensitive area of the button,
but does not change the size of the check on the screen.

Attached fluid file demonstrates this... Well, it works for me, anyway!

---------------
# data file for the Fltk User Interface Designer (fluid)
version 1.0110 
header_name {.h} 
code_name {.cxx}
decl {\#include <stdio.h>} {} 

Function {} {open
} {
  Fl_Window main_win {
    label {Check Box click-area Test} open
    xywh {515 248 539 351} type Double visible
  } {
    Fl_Button {} {
      label Quit
      callback {main_win->hide();}
      xywh {435 291 95 51}
    }
    Fl_Check_Button chk1 {
      label {Small Click Area}
      callback {puts("Click 1");
fflush(stdout);}
      xywh {25 25 25 25} down_box DOWN_BOX
    }
    Fl_Check_Button chk2 {
      label {Big Click Area}
      callback {puts("Click 2");
fflush(stdout);} selected
      xywh {25 62 138 91} down_box DOWN_BOX
    }
  }
} 

---------------
-- 
Ian



SELEX Galileo Ltd
Registered Office: Sigma House, Christopher Martin Road, Basildon, Essex SS14 
3EL
A company registered in England & Wales.  Company no. 02426132
********************************************************************
This email and any attachments are confidential to the intended
recipient and may also be privileged. If you are not the intended
recipient please delete it from your system and notify the sender.
You should not copy it or use it for any purpose nor disclose or
distribute its contents to any other person.
********************************************************************

_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to