Recent Changes - Search:

Information

Installation

Documentation

ElementsDrawingPanel

Basic container for 2D drawing. A drawing panel is a view element able to display drawable objects within a rectangular region of the plane in which it defines a world coordinate system in user-provided coordinates. Drawables, or drawing elements, are graphical objects which draw themselves (in different forms) in a given position and with a given size within a drawing panel.

Properties

Scales
NameDescriptionValues acceptedDefault
Autoscale XWhether to automatically adjust X scales.A boolean variable or one of the constants true or false. 
Autoscale YWhether to automatically adjust Y scales.A boolean variable or one of the constants true or false. 
Minimum XMinimum X value that can be displayed.A constant or variable of type double or int. 
Maximum XMaximum X value that can be displayed.A constant or variable of type double or int. 
Minimum YMinimum Y value that can be displayed.A constant or variable of type double or int. 
Maximum YMaximum Y value that can be displayed.A constant or variable of type double or int. 
SquareWhether to keep a square aspect.A boolean variable or one of the constants true or false. 
X Margin (%)The percentage of the margin in the autoscaled horizontal direction.A constant or variable of type double or int. 
Y Margin (%)The percentage of the margin in the autoscaled vertical direction.A constant or variable of type double or int. 
Interaction
NameDescriptionValues acceptedDefault
MenuDisplay popup menus in this panel.A boolean variable or one of the constants true or false. 
Menu EntryThe name to display in the simulation's corresponding elements menu entry.A string variable. 
Pos XThe X coordinate of the pointer.A constant or variable of type double or int. 
Pos YThe Y coordinate of the pointer.A constant or variable of type double or int. 
On PressThe action to invoke when the element is pressed.The Java code to invoke for the action. 
On DragThe action to invoke when the element is dragged.The Java code to invoke for the action. 
On ReleaseThe action to invoke when the element is released.The Java code to invoke for the action. 
On EnterThe action to invoke when the mouse enters the element.The Java code to invoke for the action. 
On ExitThe action to invoke when the mouse leaves the element.The Java code to invoke for the action. 
Key ActionThe action triggered when a key is pressed.The Java code to invoke for the action. 
Key PressedThe integer code of the key pressed.A integer value. 
Print TargetThe view element to print when taking a snapshot.A string constant or variable. 
Configuration
NameDescriptionValues acceptedDefault
Anti AliasingWhether to smooth lines and texts in the panel.A boolean variable or one of the constants true or false. 
GuttersGutters around the drawing area.Type the size of the four gutters or use the editor provided. 
CoordinatesWhether to display coordinates when the mouse is pressed.A boolean variable or one of the constants true or false. 
X FormatThe format to the X coordinate.The Format X property refers to the way the panel displays (in a yellow box at its lower left corner) the X coordinate when you click on a point in the panel. The special value null makes the panel not to display this coordinate."x=0.000"
Y FormatThe format to the Y coordinate.The Format Y property refers to the way the panel displays (in a yellow box at its lower left corner) the Y coordinate when you click on a point in the panel. The special value null makes the panel not to display this coordinate."y=0.000"
Messages
NameDescriptionValues acceptedDefault
ExpressionAn additional (x,y) expression to display.???? 
Expr FormatThe format for the expression.???? 
TL MessageThe message to display at the top-left corner.A string constant or variable. 
TR MessageThe message to display at the top-right corner.A string constant or variable. 
BL MessageThe message to display at the bottom-left corner.A string constant or variable. 
BR MessageThe message to display at the bottom-right corner.A string constant or variable. 
Graphical Aspect
NameDescriptionValues acceptedDefault
VisibleThe visibility of the element.A boolean variable or one of the constants true or false. 
Size The double[] array with the size of the panel in each direction.Type the two size values or use the editor provided. 
BackgroundThe background color for the element.Use the editor provided or read about colors. 
ForegroundThe color to use when drawing or writing in the element.Use the editor provided or read about colors. 
FontThe font used to display text in the element.Use the editor provided to select name, style and size of the font. 
TooltipText displayed when the mouse is over the element.A string constant or variable. 
Edit - History - Print - Recent Changes - Search
Page last modified on December 07, 2010, at 03:47 PM