|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.malai.instrument.Instrument
net.sf.latexdraw.instruments.ScaleRulersCustomiser
public class ScaleRulersCustomiser
This instrument activates X and Y scale rulers.
This file is part of LaTeXDraw
Copyright (c) 2005-2012 Arnaud BLOUIN
LaTeXDraw is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
LaTeXDraw is distributed without any warranty; without even the
implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
PURPOSE. See the GNU General Public License for more details.
11/12/10
Field Summary | |
---|---|
static java.lang.String |
LABEL_CM
The label of the centimetre menu |
static java.lang.String |
LABEL_INCH
The label of the inch menu |
protected MCheckBoxMenuItem |
unitCmItem
The menu for the centimetre unit. |
protected MCheckBoxMenuItem |
unitInchItem
The menu for the inch unit. |
protected XScaleRuler |
xRuler
The x ruler of the system. |
protected MCheckBoxMenuItem |
xRulerItem
The menu item that (des-)activate the x-scale ruler. |
protected YScaleRuler |
yRuler
The Y ruler of the system. |
protected MCheckBoxMenuItem |
yRulerItem
The menu item that (des-)activate the y-scale ruler. |
Fields inherited from class org.malai.instrument.Instrument |
---|
activated, eventables, links, modified |
Constructor Summary | |
---|---|
ScaleRulersCustomiser(XScaleRuler xRuler,
YScaleRuler yRuler)
Creates the instrument. |
Method Summary | |
---|---|
MCheckBoxMenuItem |
getUnitCmItem()
|
MCheckBoxMenuItem |
getUnitInchItem()
|
MCheckBoxMenuItem |
getxRulerItem()
|
MCheckBoxMenuItem |
getyRulerItem()
|
protected void |
initialiseLinks()
Initialises the links of the instrument. |
void |
interimFeedback()
Reinitialises the interim feedback of the instrument. |
void |
load(boolean generalPreferences,
java.lang.String nsURI,
org.w3c.dom.Element root)
Loads data save in an XML document. |
void |
onUndoableRedo(Undoable undoable)
Actions to do when an undoable object is redone. |
void |
onUndoableUndo(Undoable undoable)
Actions to do when an undoable object is undone. |
void |
save(boolean generalPreferences,
java.lang.String nsURI,
org.w3c.dom.Document document,
org.w3c.dom.Element root)
Saves the parameters of the instrument into an XML tag. |
void |
setActivated(boolean activated)
Activates or deactivates the instrument. |
protected void |
update()
|
Methods inherited from class org.malai.instrument.Instrument |
---|
addEventable, addLink, clearEvents, getLinks, getSizeLinks, hasLinks, isActivated, isModified, onActionAborted, onActionAdded, onActionCancelled, onActionDone, onActionExecuted, onUndoableAdded, reinit, removeLink, setModified |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String LABEL_CM
public static final java.lang.String LABEL_INCH
protected XScaleRuler xRuler
protected YScaleRuler yRuler
protected MCheckBoxMenuItem xRulerItem
protected MCheckBoxMenuItem yRulerItem
protected MCheckBoxMenuItem unitCmItem
protected MCheckBoxMenuItem unitInchItem
Constructor Detail |
---|
public ScaleRulersCustomiser(XScaleRuler xRuler, YScaleRuler yRuler)
xRuler
- The x ruler of the system.yRuler
- The Y ruler of the system.
java.lang.IllegalArgumentException
- If one of the given rulers is null.Method Detail |
---|
public void setActivated(boolean activated)
Instrument
setActivated
in class Instrument
activated
- True = activation.public void interimFeedback()
Instrument
interimFeedback
in class Instrument
public void onUndoableUndo(Undoable undoable)
UndoHandler
onUndoableUndo
in interface UndoHandler
onUndoableUndo
in class Instrument
undoable
- The undone object.public void onUndoableRedo(Undoable undoable)
UndoHandler
onUndoableRedo
in interface UndoHandler
onUndoableRedo
in class Instrument
undoable
- The redone object.protected void update()
protected void initialiseLinks()
Instrument
initialiseLinks
in class Instrument
public void load(boolean generalPreferences, java.lang.String nsURI, org.w3c.dom.Element root)
Preferenciable
load
in interface Preferenciable
load
in class Instrument
generalPreferences
- True: this operation is called to load the general preferences of the interactive system.
Otherwise, it is called to load a presentation in a document. This parameter is useful when different information
must be loaded during a presentation backup or a general preferences backup.nsURI
- The namespace that must be added to tags corresponding to the instrument's parameters.root
- The meta data element.public void save(boolean generalPreferences, java.lang.String nsURI, org.w3c.dom.Document document, org.w3c.dom.Element root)
Preferenciable
save
in interface Preferenciable
save
in class Instrument
generalPreferences
- True: this operation is called to save the general preferences of the interactive system.
Otherwise, it is called to save a presentation in a document. This parameter is useful when different information
must be saved during a presentation backup or a general preferences backup.nsURI
- The namespace that must be added to tags corresponding to the instrument's parameters.document
- The XML document.root
- The root element that will contains the instrument's parameters.public MCheckBoxMenuItem getxRulerItem()
public MCheckBoxMenuItem getyRulerItem()
public MCheckBoxMenuItem getUnitCmItem()
public MCheckBoxMenuItem getUnitInchItem()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |