Prev Class | Next Class | Frames | No Frames |
Summary: Nested | Field | Method | Constr | Detail: Nested | Field | Method | Constr |
GObject
org.gnu.pango.Layout
public class Layout
extends GObject
Constructor Summary | |
| |
Method Summary | |
void |
|
Alignment |
|
AttrList |
|
Context |
|
int |
|
int |
|
boolean |
|
boolean |
|
static Layout |
|
LayoutLine |
|
int |
|
int |
|
int |
|
boolean |
|
int |
|
Rectangle |
|
TabArray |
|
String |
|
Rectangle |
|
int |
|
WrapMode |
|
WrapMode |
|
Rectangle |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void |
|
void | |
void |
|
void |
|
void | |
void |
|
public Layout(Handle handle)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Construct a new Layout with a handle that has been returned from a native call.
- Parameters:
handle
- The handle to the native resource.
public Layout(Context context)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Construct a new Layout with the given Context.
- Parameters:
context
- The context to use for the Layout construction.
public Layout(Layout layout)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Construct a new Layout that is a copy of the provided Layout.
- Parameters:
layout
-
public void contextChanged()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Forces recomputation of any state in the Layout that might depend on the layout's context. This method should be called if you make changes to the context subsequent to creating the layout
public Alignment getAlignment()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets the alignment for the layout (how partial lines are positioned within the horizontal space available.)
public AttrList getAttributes()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets the attribute list for the layout, if any
public Context getContext()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Retrieve the Context used for this Layout.
public int getHeight()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Return the logical height of the Layout in Pango units.
public int getIndent()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets the amount by which the first line should be shorter than the rest of the lines.
public boolean getJustified()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets whether or not each complete line should be stretched to fill the entire width of the layout.
public boolean getJustify()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets whether or not each complete line should be stretched to fill the entire width of the layout.
public static Layout getLayoutFromHandle(Handle handle)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Static factory method that should only be used interally by Java-Gnome.
public LayoutLine getLine(int line)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Retrieves a particular line from a Layout.
- Parameters:
line
- the index of a line, which must be between 0 and pango_layout_get_line_count(layout) - 1, inclusive.
- Returns:
- the requested LayoutLine.
public int getLineCount()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Retrieve the count of lines for the layout
public int getPixelHeight()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Return the logical height of the Layout in device units.
public int getPixelWidth()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Return the logical width of the Layout in device units.
public boolean getSingleParagraphMode()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Obtains the value set bysetSingleParagraphMode(boolean)
.
public int getSpacing()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets the amount of spacing between the lines of the layout.
- Returns:
- the spacing (in thousandths of a device unit)
public Rectangle getStrongCursorPosition(int index)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Given an index within a layout, determines the positions that of the strong cursor if the insertion point is at that index. The position of each cursor is stored as a zero-width rectangle. The strong cursor location is the location where characters of the directionality equal to the base direction of the layout are inserted.
- Parameters:
index
-
public TabArray getTabs()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets the current TabArray used by this layout. If no TabArray has been set, then the default tabs are in use and null is returned. Default tabs are every 8 spaces.
public String getText()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets the text in the layout.
public Rectangle getWeakCursorPosition(int index)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Given an index within a layout, determines the positions that of the weak cursor if the insertion point is at that index. The position of each cursor is stored as a zero-width rectangle. The weak cursor location is the location where characters of the directionality opposite to the base direction of the layout are inserted.
- Parameters:
index
-
public int getWidth()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Gets the width to which the lines of the PangoLayout should be wrapped.
public WrapMode getWrap()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Get the wrap mode for the layout.
public WrapMode getWrapMode()
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Get the wrap mode for the layout.
public Rectangle indexToPos(int index)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Converts from an index within a Layout to the onscreen position corresponding to the grapheme at that index, which is represented as rectangle. Note that pos->x is always the leading edge of the grapheme and pos->x + pos->width the trailing edge of the grapheme. If the directionality of the grapheme is right-to-left, then pos->width will be negative.
- Parameters:
index
-
public void setAlignment(Alignment alignment)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the alignment for the layout (how partial lines are positioned within the horizontal space available.)
public void setAttributes(AttrList attributes)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the text attributes for a layout object
public void setFontDescription(FontDescription desc)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Set the default font description for the layout. If no font description is set on the layout, the font description from the layout's context is used.
public void setIndent(int indent)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the amount by which the first line should be shorter than the rest of the lines. This may be negative, in which case the subsequent lines will be shorter than the first line. (However, in either case, the entire width of the layout will be given by the value
public void setJustification(boolean justify)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets whether or not each complete line should be stretched to fill the entire width of the layout. This stretching is typically done by adding whitespace, but for some scripts (such as Arabic), the justification is done by extending the characters.
public void setJustify(boolean justify)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets whether or not each complete line should be stretched to fill the entire width of the layout. This stretching is typically done by adding whitespace, but for some scripts (such as Arabic), the justification is done by extending the characters.
public void setMarkup(String markup)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Same assetMarkup(String,char)
, but the markup text isn't scanned for accelerators.
public void setMarkup(String markup, char accelMarker)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the layout text and attribute list from marked-up text (see markup format). Replaces the current text and attribute list. If accelMarker is nonzero, the given character will mark the character following it as an accelerator. For example, the accel marker might be an ampersand or underscore. All characters marked as an accelerator will receive aUnderline.LOW
attribute. Two accelMarker characters following each other produce a single literal accelMarker character.
- Parameters:
markup
- some marked-up textaccelMarker
- : marker for accelerators in the text
public void setSingleParagraphMode(boolean setting)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
If setting is TRUE, do not treat newlines and similar characters as paragraph separators; instead, keep all text in a single paragraph, and display a glyph for paragraph separator characters. Used when you want to allow editing of newlines on a single text line.
public void setSpacing(int spacing)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the amount of spacing between the lines of the layout.
public void setTabs(TabArray tabs)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the tabs to use for layout, overriding the default tabs (by default, tabs are every 8 spaces).
public void setText(String text)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Set the text of the layout.
public void setWidth(int width)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the width to which the lines of the PangoLayout should be wrapped.
public void setWrap(WrapMode wrap)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the wrap style; the wrap style only has an effect if a width is set on the layout withsetWidth(int)
To turn off wrapping, set the width to -1.
public void setWrapStyle(WrapMode wrap)
Deprecated. Superceeded by java-gnome 4.0; this method or constant will no doubt exist conceptually, but it may have a different name or signature in order that the presented API is an algorithmic mapping of the underlying native libraries.
Sets the wrap style; the wrap style only has an effect if a width is set on the layout withsetWidth(int)
To turn off wrapping, set the width to -1.