Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Eclipse GEF
3.3

org.eclipse.gef.ui.rulers
Class RulerComposite

java.lang.Object
  extended byComposite
      extended by
org.eclipse.gef.ui.rulers.RulerComposite

public class RulerComposite
extends Composite

A RulerComposite is used to show rulers to the north and west of the control of a given graphical viewer. The rulers will be shown based on whether or not horizontal ruler and vertical ruler properties are set on the given viewer, and the value of the visibility property.

Since:
3.0
See Also:
Serialized Form

Constructor Summary
RulerComposite (Composite parent, int style)
          Constructor
 
Method Summary
 void layout (boolean change)
           
 void setGraphicalViewer ( ScrollingGraphicalViewer primaryViewer)
          Creates rulers for the given graphical viewer.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RulerComposite

public RulerComposite(Composite parent,
                      int style)
Constructor

Parameters:
parent - a widget which will be the parent of the new instance (cannot be null)
style - the style of widget to construct
See Also:
Composite#Composite(org.eclipse.swt.widgets.Composite, int)
Method Detail

layout

public void layout(boolean change)
See Also:
org.eclipse.swt.widgets.Composite#layout(boolean)

setGraphicalViewer

public void setGraphicalViewer(
ScrollingGraphicalViewer primaryViewer)
Creates rulers for the given graphical viewer.

The primaryViewer or its Control cannot be null. The primaryViewer's Control should be a FigureCanvas and a child of this Composite. This method should only be invoked once.

To create ruler(s), simply add the RulerProvider(s) (with the right key: RulerProvider.PROPERTY_HORIZONTAL_RULER or RulerProvider.PROPERTY_VERTICAL_RULER) as a property on the given viewer. It can be done after this method is invoked. RulerProvider.PROPERTY_RULER_VISIBILITY can be used to show/hide the rulers.

Parameters:
primaryViewer - The graphical viewer for which the rulers have to be created

Eclipse GEF
3.3

Copyright (c) IBM Corp. and others 2000, 2007. All Rights Reserved.

 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire