public class CmsUiUtils extends java.lang.Object implements CmsConstants
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
LOREM_IPSUM
Lorem ipsum text to be used during development.
|
static org.eclipse.swt.layout.RowData |
ROW_DATA_16px
Deprecated.
Use rowData16px() instead. GridData should not be reused.
|
DATE_TIME_FORMAT, HYPERLINK, ITEM_HEIGHT, LOADING_IMAGE, MARKUP, NO_IMAGE, NO_IMAGE_RATIO, NO_IMAGE_SIZE, STYLE
Modifier and Type | Method and Description |
---|---|
static Node |
child(Node parent,
java.lang.Enum<?> en) |
static void |
clear(org.eclipse.swt.widgets.Composite composite)
Dispose all children of a Composite
|
static org.eclipse.swt.layout.GridData |
fillAll() |
static org.eclipse.swt.layout.GridData |
fillWidth() |
static CmsView |
getCmsView()
The CMS view related to this display, or null if none is available from this
call.
|
static java.lang.String |
getDataPath(Node node)
A path in the node repository
|
static java.lang.String |
getDataPath(java.lang.String cn,
Node node) |
static java.lang.String |
getDataUrl(Node node,
javax.servlet.http.HttpServletRequest request) |
static Node |
getOrAdd(Node parent,
java.lang.Enum<?> en) |
static Node |
getOrAdd(Node parent,
java.lang.Enum<?> en,
java.lang.String primaryType) |
static Node |
getOrAddEmptyFile(Node parent,
java.lang.Enum<?> child) |
static java.lang.StringBuilder |
getServerBaseUrl(javax.servlet.http.HttpServletRequest request) |
static org.eclipse.swt.layout.GridData |
grabWidth(int horizontalAlignment,
int verticalAlignment) |
static java.lang.Boolean |
has(Node parent,
java.lang.Enum<?> en) |
static java.lang.String |
img(java.lang.String src,
org.eclipse.swt.graphics.Point size) |
static java.lang.String |
img(java.lang.String src,
java.lang.String width,
java.lang.String height) |
static java.lang.StringBuilder |
imgBuilder(java.lang.String src,
java.lang.String width,
java.lang.String height) |
static org.eclipse.swt.widgets.Label |
lbl(org.eclipse.swt.widgets.Composite parent,
java.lang.Object txt)
A
Label with markup activated. |
static <T extends org.eclipse.swt.widgets.Widget> |
markup(T widget)
Enable markups on widget
|
static org.eclipse.swt.graphics.Image |
noImage(org.eclipse.swt.graphics.Point size) |
static java.lang.String |
noImg() |
static java.lang.String |
noImg(org.eclipse.swt.graphics.Point size) |
static org.eclipse.swt.layout.GridLayout |
noSpaceGridLayout() |
static org.eclipse.swt.layout.GridLayout |
noSpaceGridLayout(org.eclipse.swt.layout.GridLayout layout) |
static org.eclipse.swt.layout.GridLayout |
noSpaceGridLayout(int columns) |
static org.eclipse.swt.layout.RowData |
rowData16px() |
static void |
setItemHeight(org.eclipse.swt.widgets.Table table,
int height) |
static <T extends org.eclipse.swt.widgets.Widget> |
style(T widget,
java.lang.String style)
Style widget
|
static <T extends org.eclipse.swt.widgets.Widget> |
text(T widget,
java.lang.Object txt)
Apply markup and set text on
Label , Button , Text . |
static org.eclipse.swt.widgets.Text |
txt(org.eclipse.swt.widgets.Composite parent,
java.lang.Object txt)
A read-only
Text whose content can be copy/pasted. |
@Deprecated public static org.eclipse.swt.layout.RowData ROW_DATA_16px
public static final java.lang.String LOREM_IPSUM
public static CmsView getCmsView()
public static java.lang.StringBuilder getServerBaseUrl(javax.servlet.http.HttpServletRequest request)
public static java.lang.String getDataUrl(Node node, javax.servlet.http.HttpServletRequest request) throws RepositoryException
RepositoryException
public static java.lang.String getDataPath(Node node) throws RepositoryException
RepositoryException
public static java.lang.String getDataPath(java.lang.String cn, Node node) throws RepositoryException
RepositoryException
public static org.eclipse.swt.layout.GridLayout noSpaceGridLayout()
public static org.eclipse.swt.layout.GridLayout noSpaceGridLayout(int columns)
public static org.eclipse.swt.layout.GridLayout noSpaceGridLayout(org.eclipse.swt.layout.GridLayout layout)
public static org.eclipse.swt.layout.GridData fillWidth()
public static org.eclipse.swt.layout.GridData fillAll()
public static org.eclipse.swt.layout.GridData grabWidth(int horizontalAlignment, int verticalAlignment)
public static org.eclipse.swt.layout.RowData rowData16px()
public static <T extends org.eclipse.swt.widgets.Widget> T style(T widget, java.lang.String style)
public static <T extends org.eclipse.swt.widgets.Widget> T markup(T widget)
public static <T extends org.eclipse.swt.widgets.Widget> T text(T widget, java.lang.Object txt)
Label
, Button
, Text
.widget
- the widget to style and to use in order to display texttxt
- the object to display via its toString()
method.
This argument should not be null, but if it is null and
assertions are disabled "markup(Widget)
public static org.eclipse.swt.widgets.Label lbl(org.eclipse.swt.widgets.Composite parent, java.lang.Object txt)
Label
with markup activated.public static org.eclipse.swt.widgets.Text txt(org.eclipse.swt.widgets.Composite parent, java.lang.Object txt)
Text
whose content can be copy/pasted.public static void setItemHeight(org.eclipse.swt.widgets.Table table, int height)
public static void clear(org.eclipse.swt.widgets.Composite composite)
public static Node getOrAddEmptyFile(Node parent, java.lang.Enum<?> child) throws RepositoryException
RepositoryException
public static Node child(Node parent, java.lang.Enum<?> en) throws RepositoryException
RepositoryException
public static java.lang.Boolean has(Node parent, java.lang.Enum<?> en) throws RepositoryException
RepositoryException
public static Node getOrAdd(Node parent, java.lang.Enum<?> en) throws RepositoryException
RepositoryException
public static Node getOrAdd(Node parent, java.lang.Enum<?> en, java.lang.String primaryType) throws RepositoryException
RepositoryException
public static java.lang.String img(java.lang.String src, java.lang.String width, java.lang.String height)
public static java.lang.String img(java.lang.String src, org.eclipse.swt.graphics.Point size)
public static java.lang.StringBuilder imgBuilder(java.lang.String src, java.lang.String width, java.lang.String height)
public static java.lang.String noImg(org.eclipse.swt.graphics.Point size)
public static java.lang.String noImg()
public static org.eclipse.swt.graphics.Image noImage(org.eclipse.swt.graphics.Point size)
Copyright © 2007–2020. All rights reserved.