mirror of
https://github.com/fltk/fltk.git
synced 2026-06-06 16:46:52 +08:00
Prefer fl_push_clip() over fl_clip().
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2307 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
@@ -34,7 +34,7 @@ Fl_Double_Window</TT>. </P>
|
||||
draw()</TT> method that draws the contents. The scrolling is done by
|
||||
changing the <TT>x()</TT> and <TT>y()</TT> of the widget, so this child
|
||||
must use the <TT>x()</TT> and <TT>y()</TT> to position it's drawing.
|
||||
To speed up drawing it should test <A href=drawing.html#fl_clip><TT>fl_clip()</TT></A>
|
||||
To speed up drawing it should test <A href=drawing.html#fl_push_clip><TT>fl_push_clip()</TT></A>
|
||||
. </P>
|
||||
<P>Another very useful child is a single <A href=Fl_Pack.html#Fl_Pack><TT>
|
||||
Fl_Pack</TT></A>, which is itself a group that packs it's children
|
||||
|
||||
@@ -67,18 +67,19 @@ following types of drawing functions:
|
||||
<H3><A name="clipping">Clipping</A></H3>
|
||||
|
||||
<P>You can limit all your drawing to a rectangular region by calling
|
||||
<TT>fl_clip</TT>, and put the drawings back by using <TT>fl_pop_clip</TT>.
|
||||
<TT>fl_push_clip</TT>, and put the drawings back by using <TT>fl_pop_clip</TT>.
|
||||
This rectangle is measured in pixels and is unaffected by the current
|
||||
transformation matrix.
|
||||
|
||||
<P>In addition, the system may provide clipping when updating windows
|
||||
which may be more complex than a simple rectangle.</P>
|
||||
|
||||
<H4><A name="fl_clip">void fl_push_clip(int x, int y, int w, int h)</A><BR>
|
||||
void fl_clip(int x, int y, int w, int h)</H4>
|
||||
<H4><A name="fl_push_clip">void fl_clip(int x, int y, int w, int h)</A><BR>
|
||||
void fl_push_clip(int x, int y, int w, int h)</H4>
|
||||
|
||||
<P>Intersect the current clip region with a rectangle and push this new
|
||||
region onto the stack.
|
||||
region onto the stack. The <CODE>fl_clip()</CODE> name is deprecated and
|
||||
will be removed from future releases.
|
||||
|
||||
<H4>void fl_push_no_clip()</H4>
|
||||
|
||||
@@ -93,7 +94,7 @@ region onto the stack.
|
||||
<TD><B>Note:</B>
|
||||
|
||||
<P>You must call <TT>fl_pop_clip()</TT> once for every
|
||||
time you call <TT>fl_clip()</TT>. If you return to FLTK
|
||||
time you call <TT>fl_push_clip()</TT>. If you return to FLTK
|
||||
with the clip stack not empty unpredictable results
|
||||
occur.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user