com.levigo.jadice.swing.tool
Class DecorationTool
java.lang.Object
com.levigo.jadice.swing.tool.Tool
com.levigo.jadice.swing.tool.DecorationTool
- All Implemented Interfaces:
- MenuContributor
public class DecorationTool
- extends Tool
This tool is used to apply page decorations. It allows the usage of DecorationRenderer
on
any ViewComponent
s. Therefore it bridges Tool.render(RenderParameters, boolean)
calls to a contained DecorationRenderer
. If no renderer is set to this by a call of
setRenderer(DecorationRenderer)
, this tool will do nothing.
Methods inherited from class com.levigo.jadice.swing.tool.Tool |
contribute, getActivationFeedback, getActivationRequest, getActivationRequestForKeyPressed, getActivationRequestForMouseDragged, getActivationRequestForMousePressed, getCursor, getDispatchPriority, getManager, getRenderPriority, handleEditEvent, handleKeyPressed, handleKeyReleased, handleKeyTyped, handleMouseClicked, handleMouseDragged, handleMouseEntered, handleMouseExited, handleMouseMoved, handleMousePressed, handleMouseReleased, handleMouseWheelMoved, propagatePropertyChange, setActive, setCursor, setEnabled, setManager, setStatusFeedback |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DecorationTool
public DecorationTool()
- Constructor
render
protected void render(RenderParameters parameters,
boolean isActive)
- Description copied from class:
Tool
- Renders the Tool's UI onto the given
Graphics2D
context using the given
RenderControls
.
This render method is called within the context and during the rendering of a single page. The
page being rendered is passed to implementors of this method in order to be able to control and
influence the page rendering.
- Overrides:
render
in class Tool
- Parameters:
parameters
- the view component which is currently being renderedisActive
- whether the called tool is currently active
getRenderer
public DecorationRenderer getRenderer()
- Returns the decoration renderer to which this
Tool.render(RenderParameters, boolean)
calls are bridged to
DecorationRenderer.decorate(com.levigo.jadice.document.render.BasicRenderParameters)
calls.
- Returns:
DecorationRenderer
or null
if no renderer is available- See Also:
setRenderer(DecorationRenderer)
setRenderer
public void setRenderer(DecorationRenderer renderer)
- Changes the decoration renderer which is used by this too
- Parameters:
renderer
- - See Also:
getRenderer()
Copyright © 1995-2020 levigo holding gmbh. All Rights Reserved.