Interface ILayoutRegion<I extends ILayoutRegion>
-
- All Superinterfaces:
IComponent<I>,IHtmlBasedComponent<I>,IXulElement<I>
public interface ILayoutRegion<I extends ILayoutRegion> extends IXulElement<I>
ImmutableLayoutRegioninterfaceThis class represents a region in a layout manager.
Support @Action
Name Action Type onOpen ActionData: OpenData
When a layout is collapsed or opened by a user, theonOpenaction is sent to the application.onSize ActionData: SizeData
When a layout is resized by a user, theonSizeaction is sent to the application..onSlide ActionData: SlideData
When a collapsed layout is slided (preview) by a user, theonSlideaction is sent to the application.Support Application Library Properties
-
To set to use Browser's scrollbar or not, you have to specify
withNativeScrollbar(boolean).Or configure it from zk.xml by setting library properties. For example,
<library-property/> <name>org.zkoss.zul.nativebar</name/> <value>false</value/> </library-property/>
- Author:
- katherine
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classILayoutRegion.BorderSpecifies the border toILayoutRegioncomponent.
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default java.lang.StringgetBorder()Returns the border.default java.lang.StringgetMargins()Returns the margins, which is a list of numbers separated by comma.default intgetMaxsize()Returns the maximum size of the resizing component.default intgetMinsize()Returns the minimum size of the resizing component.java.lang.StringgetTitle()Returns the title.default booleanisAutoscroll()Returns whether enable overflow scrolling.default booleanisClosable()Returns whether users can open or close the region.default booleanisCollapsible()Returns whether set the initial display to collapse.default booleanisNativeScrollbar()Returns whether to use Browser's scrollbar or a floating scrollbar (if withfalse).default booleanisOpen()Returns whether it is open (i.e., not collapsed.default booleanisSlidable()Returns whether users can slide (preview) the region when clicked on a collapsed region.default booleanisSlide()Returns whether it is slide down.default booleanisSplittable()Returns whether enable the split functionality.IwithAutoscroll(boolean autoscroll)Returns a copy ofthisimmutable component with the specifiedautoscroll.IwithBorder(java.lang.String border)Returns a copy ofthisimmutable component with the specifiedborder.default IwithBorder(ILayoutRegion.Border border)Returns a copy ofthisimmutable component with the specifiedborder.IwithClosable(boolean closable)Returns a copy ofthisimmutable component with the specifiedclosable.IwithCollapsible(boolean collapsible)Returns a copy ofthisimmutable component with the specifiedcollapsible.IwithMargins(java.lang.String margins)Returns a copy ofthisimmutable component with the specifiedmargins.IwithMaxsize(int maxsize)Returns a copy ofthisimmutable component with the specifiedmaxsize.IwithMinsize(int minsize)Returns a copy ofthisimmutable component with the specifiedminsize.IwithNativeScrollbar(boolean nativeScrollbar)Returns a copy ofthisimmutable component with the specifiednativeScrollbar.IwithOpen(boolean open)Returns a copy ofthisimmutable component with the specifiedopen.IwithSlidable(boolean slidable)Returns a copy ofthisimmutable component with the specifiedslidable.IwithSlide(boolean slide)Returns a copy ofthisimmutable component with the specifiedslidable.IwithSplittable(boolean splittable)Returns a copy ofthisimmutable component with the specifiedsplittable.IwithTitle(java.lang.String title)Returns a copy ofthisimmutable component with the specifiedtitle.-
Methods inherited from interface org.zkoss.stateless.sul.IComponent
getAction, getActions, getClientAttributes, getId, getMold, getWidgetClass, getWidgetListeners, getWidgetOverrides, isVisible, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withAction, withActions, withActions, withClientAttribute, withClientAttributes, withId, withMold, withVisible, withWidgetClass, withWidgetListener, withWidgetListeners, withWidgetOverride, withWidgetOverrides
-
Methods inherited from interface org.zkoss.stateless.sul.IHtmlBasedComponent
getClientAction, getDraggable, getDroppable, getHeight, getHflex, getLeft, getRenderdefer, getSclass, getStyle, getTabindex, getTooltiptext, getTop, getVflex, getWidth, getZclass, getZIndex, isFocus, withClientAction, withDraggable, withDroppable, withFocus, withHeight, withHflex, withLeft, withRenderdefer, withSclass, withStyle, withTabindex, withTabindex, withTooltiptext, withTop, withVflex, withWidth, withZclass, withZIndex
-
Methods inherited from interface org.zkoss.stateless.sul.IXulElement
getContext, getCtrlKeys, getPopup, getTooltip, withContext, withCtrlKeys, withPopup, withTooltip
-
-
-
-
Method Detail
-
getTitle
@Nullable java.lang.String getTitle()
Returns the title.Default:
null.
-
withTitle
I withTitle(@Nullable java.lang.String title)
Returns a copy ofthisimmutable component with the specifiedtitle.Sets the title of this component.
- Parameters:
title- The title of this component.Default:
null(empty).- Returns:
- A modified copy of the
thisobject
-
getBorder
default java.lang.String getBorder()
Returns the border.The border actually controls what CSS class to use: If border is null, it implies
"none".If you also specify the CSS class (
IHtmlBasedComponent.withSclass(java.lang.String)), it overwrites whatever border you specify here.Default:
"normal".
-
withBorder
I withBorder(java.lang.String border)
Returns a copy ofthisimmutable component with the specifiedborder.Sets the border. Allowed values include
none(default), andnormal.- Parameters:
border- the border. If null,"0"or"false","none"is assumed.- Returns:
- A modified copy of the
thisobject
-
withBorder
default I withBorder(ILayoutRegion.Border border)
Returns a copy ofthisimmutable component with the specifiedborder.Sets the border with the given
border.- Parameters:
border- The border- Returns:
- A modified copy of the
thisobject
-
isAutoscroll
default boolean isAutoscroll()
Returns whether enable overflow scrolling.Default:
false.
-
withAutoscroll
I withAutoscroll(boolean autoscroll)
Returns a copy ofthisimmutable component with the specifiedautoscroll.Sets whether enable overflow scrolling.
- Parameters:
autoscroll- Whether enable overflow scrolling.- Returns:
- A modified copy of the
thisobject
-
getMargins
default java.lang.String getMargins()
Returns the margins, which is a list of numbers separated by comma.Default: "0,0,0,0".
-
withMargins
I withMargins(java.lang.String margins)
Returns a copy ofthisimmutable component with the specifiedmargins.Sets margins for the element "0,1,2,3" that direction is "top,left,right,bottom"
- Parameters:
margins- The margins of the region.- Returns:
- A modified copy of the
thisobject
-
getMaxsize
default int getMaxsize()
Returns the maximum size of the resizing component.Default:
2000.
-
withMaxsize
I withMaxsize(int maxsize)
Returns a copy ofthisimmutable component with the specifiedmaxsize.Sets the maximum size of the resizing component.
- Parameters:
maxsize- The maximum size of the resizing component.- Returns:
- A modified copy of the
thisobject
-
getMinsize
default int getMinsize()
Returns the minimum size of the resizing component.Default:
0.
-
withMinsize
I withMinsize(int minsize)
Returns a copy ofthisimmutable component with the specifiedminsize.Sets the minimum size of the resizing component.
- Parameters:
minsize- The minimum size of the resizing component.- Returns:
- A modified copy of the
thisobject
-
isSplittable
default boolean isSplittable()
Returns whether enable the split functionality.Default:
false.
-
withSplittable
I withSplittable(boolean splittable)
Returns a copy ofthisimmutable component with the specifiedsplittable.Sets whether enable the split functionality.
- Parameters:
splittable- Whether enable the split functionality.- Returns:
- A modified copy of the
thisobject
-
isCollapsible
default boolean isCollapsible()
Returns whether set the initial display to collapse.It only applied when
getTitle()is not null.Default:
false.
-
withCollapsible
I withCollapsible(boolean collapsible)
Returns a copy ofthisimmutable component with the specifiedcollapsible.Sets whether set the initial display to collapse.
It only applied when
getTitle()is not null.- Parameters:
collapsible- Whether set the initial display to collapse.- Returns:
- A modified copy of the
thisobject
-
isOpen
default boolean isOpen()
Returns whether it is open (i.e., not collapsed. Meaningful only ifisCollapsible()is not false).Default:
true.
-
withOpen
I withOpen(boolean open)
Returns a copy ofthisimmutable component with the specifiedopen.Sets whether it is open (i.e., not collapsed. Meaningful only if
isCollapsible()is not false).- Parameters:
open- Whether to open.- Returns:
- A modified copy of the
thisobject
-
isSlidable
default boolean isSlidable()
Returns whether users can slide (preview) the region when clicked on a collapsed region. In other words, if false, clicking on a collapsed region will open it instead of sliding.Default:
true.
-
withSlidable
I withSlidable(boolean slidable)
Returns a copy ofthisimmutable component with the specifiedslidable.Sets whether users can slide (preview) the region when clicked on a collapsed region. In other words, if false, clicking on a collapsed region will open it instead of sliding.
- Parameters:
slidable- Whether users can slide this region.Default:
true.- Returns:
- A modified copy of the
thisobject
-
isSlide
default boolean isSlide()
Returns whether it is slide down.Default:
false.
-
withSlide
I withSlide(boolean slide)
Returns a copy ofthisimmutable component with the specifiedslidable.Sets whether slides down or up the region. Meaningful only if
isCollapsible()is not false andisOpen()is false.- Parameters:
slide- Whether slides down or up the regionDefault:
false.- Returns:
- A modified copy of the
thisobject
-
isClosable
default boolean isClosable()
Returns whether users can open or close the region. In other words, if false, users are no longer allowed to change the open status (by clicking the button on the bar).Default:
true.
-
withClosable
I withClosable(boolean closable)
Returns a copy ofthisimmutable component with the specifiedclosable.Sets whether users can open or close the region.
- Parameters:
closable- Whether users can open or close the region.Default:
true.- Returns:
- A modified copy of the
thisobject
-
isNativeScrollbar
default boolean isNativeScrollbar()
Returns whether to use Browser's scrollbar or a floating scrollbar (if withfalse).Default:
trueto use Browser's scrollbar, if the"org.zkoss.zul.nativebar"library property is not set in zk.xml.
-
withNativeScrollbar
I withNativeScrollbar(boolean nativeScrollbar)
Returns a copy ofthisimmutable component with the specifiednativeScrollbar.Sets to use Browser's scrollbar or a floating scrollbar
- Parameters:
nativeScrollbar-trueto use Browser's scrollbar, orfalseto use a floating scrollbar.Default:
true.- Returns:
- A modified copy of the
thisobject
-
-