Lines Matching defs:to

8  * particular file as subject to the "Classpath" exception as provided
18 * 2 along with this work; if not, write to the Free Software Foundation,
34 * providing a way to undo or redo the appropriate edits. There are
35 * two ways to add edits to an <code>UndoManager</code>. Add the edit
37 * <code>UndoManager</code> to a bean that supports
40 * <code>UndoableEditListener</code> to a <code>JTextField</code>:
50 * <code>undo</code> has been invoked it corresponds to the index
53 * edit to the last significant edit are undone, in reverse order.
69 * index of the next edit to 3 (edit <i>c</i>), as shown in the following
82 * next edit to 0, as shown in the following figure.
96 * the index of the next edit is set to 3 (as shown in <a
99 * Adding an edit to an <code>UndoManager</code> results in
100 * removing all edits from the index of the next edit to the end of
119 * methods. Refer to <code>CompoundEdit</code> for more details on its
130 * has been added to the <code>java.beans</code> package.
180 * Reduces the number of queued edits to a range of size limit,
207 // isn't. Move the keep range to keep it legal.
231 * <code>from</code> &gt; <code>to</code>.
233 * @param from the minimum index to remove
234 * @param to the maximum index to remove
236 protected void trimEdits(int from, int to) {
237 if (from <= to) {
238 // System.out.println("Trimming " + from + " " + to + " with index " +
240 for (int i = to; from <= i; i--) {
250 if (indexOfNextAdd > to) {
252 indexOfNextAdd -= to-from+1;
265 * limited. If edits need to be discarded to shrink the limit,
278 if (!inProgress) throw new RuntimeException("Attempt to call UndoManager.setLimit() after UndoManager.end() has been called");
285 * Returns the the next significant edit to be undone if <code>undo</code>
287 * to be undone.
289 * @return the next significant edit to be undone
304 * Returns the the next significant edit to be redone if <code>redo</code>
306 * to be redone.
308 * @return the next significant edit to be redone
325 * Undoes all changes from the index of the next edit to
341 * Redoes all changes from the index of the next edit to
379 * Returns true if it is possible to invoke <code>undo</code> or
395 * invoked this calls through to the superclass, otherwise
402 * to be undone
422 * this returns true if there are any edits to be undone
425 * @return true if there are edits to be undone
440 * invoked this calls through to the superclass. Otherwise
447 * to be redone
467 * this returns true if there are any edits to be redone
470 * @return true if there are edits to be redone
484 * Adds an <code>UndoableEdit</code> to this
486 * edits from the index of the next edit to the end of the edits
491 * @param anEdit the edit to be added
500 // Trim from the indexOfNextAdd to the end, as we'll
555 * Otherwise if there are edits to be undone, this returns
557 * If there are no edits to be undone and <code>end</code> has not
580 * Otherwise if there are edits to be redone, this returns
582 * If there are no edits to be redone and <code>end</code> has not