|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface IDocumentPane
Interface of any document interface.
Field Summary | |
---|---|
static int |
CLOSE_ACTION_TO_CLOSE
|
static int |
CLOSE_ACTION_TO_DOCK
|
static int |
FLOATING_CONTAINER_TYPE_DIALOG
|
static int |
FLOATING_CONTAINER_TYPE_FRAME
|
Method Summary | |
---|---|
void |
activateGroup(IDocumentGroup documentGroup)
Activate the document group. |
void |
closeAll()
Closes all documents. |
void |
closeAllButThis(String documentName)
Closes all documents except the one specified as parameter. |
void |
closeDocument(String name)
Removes the component that identified by name . |
void |
closeDocuments(FloatingDocumentContainer container)
Closes all floating documents inside the floating container. |
void |
closeSingleDocument(String documentName)
Closes a single document. |
void |
dispose()
Dispose DocumentPane. |
void |
dockDocument(String documentName)
Docks a floating document back that was floated before. |
void |
dockDocuments(FloatingDocumentContainer container)
Docks all floating documents inside the floating container. |
void |
floatDocument(FloatingDocumentContainer floatingContainer,
String documentName)
Floating a document of the specified name into a specified floating container. |
void |
floatDocument(String documentName)
Floating a document of the specified name. |
DocumentComponent |
getActiveDocument()
Gets the active component. |
String |
getActiveDocumentName()
Gets key of the active component. |
DocumentComponent |
getDocument(String name)
Gets document whose name is name . |
DocumentComponent |
getDocumentAt(int index)
Gets document at the specified index. |
int |
getDocumentCount()
Return the total number of open documents. |
IDocumentGroup |
getDocumentGroup(String documentName)
Gets the document group that contains the document with the specified document name. |
IDocumentGroup |
getDocumentGroupAt(int index)
Gets document group at the specified index. |
int |
getDocumentGroupCount()
Gets the number of document groups. |
String |
getDocumentNameAt(int index)
Gets document at position specified in index . |
String[] |
getDocumentNames()
Return an array of DocumentComponents. |
int |
getFloatingContainerCloseAction()
Gets the action when the native close button is pressed on the floating container. |
List<FloatingDocumentContainer> |
getFloatingContainers()
Gets the list of floating containers. |
int |
getFloatingContainerType()
Gets the floating container type. |
LayoutPersistence |
getLayoutPersistence()
Gets the layout persistence that can be used to persist the documents that are opened in document pane. |
String |
getNameOf(Component component)
Gets name of document whose component is component . |
PopupMenuCustomizer |
getPopupMenuCustomizer()
Gets the popup menu customizer. |
int |
getSelectedIndexAtGroupIndex(int index)
Gets the selected document index in the document group at the specified index. |
StringConverter |
getTitleConverter()
Gets the title converter that convert the title. |
int |
groupIndexOfDocument(String name)
Gets group index of the document. |
int |
indexOfDocument(String name)
Gets index of the document in it's group. |
boolean |
isDocumentFloating(String documentName)
Checks if the document is floating. |
boolean |
isDocumentOpened(String name)
Check if the document with the name is opened. |
boolean |
isGroupsAllowed()
Is document group allowed in this document pane. |
boolean |
isHeavyweightComponentEnabled()
|
boolean |
isReorderAllowed()
Checks if document order is allowed to changed by user. |
void |
moveDocument(String name,
int groupIndex)
Move the document identified by name to a new group whose index is groupIndex . |
void |
moveDocument(String name,
int groupIndex,
int tabIndex)
Move the document identified by name to a new group whose index is groupIndex . |
void |
newDocumentGroup(String name,
int groupIndex,
int orientation)
New a document group and put the document with name to the new group. |
void |
nextDocument()
Sets next document as active. |
void |
openDocument(DocumentComponent document)
Inserts the component into this pane. |
void |
prevDocument()
Sets previous document as active. |
void |
renameDocument(String oldName,
String newName)
Renames the document with the old name to the new name. |
void |
setActiveDocument(String documentName)
Sets the tab that identified by name as active. |
void |
setActiveDocument(String documentName,
boolean requestFocus)
Sets the tab that identified by name as active. |
void |
setDocumentEnabled(String name,
boolean enabled)
Enables or disables the document that identified by name . |
void |
setFloatingContainerCloseAction(int action)
Sets the action when the native close button is pressed on the floating container. |
void |
setFloatingContainerType(int floatingContainerType)
Sets the floating container type. |
void |
setGroupsAllowed(boolean groupsAllowed)
Sets if document group is allowed is this document pane. |
void |
setHeavyweightComponentEnabled(boolean heavyweightComponentEnabled)
Enables heavyweight component. |
void |
setOpenedDocuments(List<DocumentComponent> documentComponents)
Sets the opened components. |
void |
setPopupMenuCustomizer(PopupMenuCustomizer customizer)
Sets the popup customizer. |
void |
setReorderAllowed(boolean reorderAllowed)
Sets if document order is allowed to be changed by user. |
void |
setTitleConverter(StringConverter titleConverter)
Sets the title converter. |
void |
updateDocument(String documentName)
Updates document title when user changes the title. |
Field Detail |
---|
static final int CLOSE_ACTION_TO_CLOSE
static final int CLOSE_ACTION_TO_DOCK
static final int FLOATING_CONTAINER_TYPE_DIALOG
static final int FLOATING_CONTAINER_TYPE_FRAME
Method Detail |
---|
void openDocument(DocumentComponent document)
document
- document to be openedvoid closeDocument(String name)
name
.
name
- namevoid closeAll()
void closeSingleDocument(String documentName)
closeAll()
and closeAllButThis(String)
will eventually call this
method to close each document. This method will call closeDocument(String)
by default. However subclass
can override this method to do additional logic.
You can refer to http://www.jidesoft.com/forum/viewtopic.php?p=10262#10262 to see the reason of adding this
method.
documentName
- the document name.void closeAllButThis(String documentName)
documentName
- the document name.void setActiveDocument(String documentName)
documentName
- the document name.void setActiveDocument(String documentName, boolean requestFocus)
documentName
- the document name.requestFocus
- true to request focus on the document. Otherwise false.DocumentComponent getActiveDocument()
String getActiveDocumentName()
void nextDocument()
void prevDocument()
void moveDocument(String name, int groupIndex)
groupIndex
.
name
- name of the documentgroupIndex
- index of dest groupvoid moveDocument(String name, int groupIndex, int tabIndex)
groupIndex
.
name
- name of the documentgroupIndex
- index of dest grouptabIndex
- index of the dest tabvoid newDocumentGroup(String name, int groupIndex, int orientation)
name
- name of the documentgroupIndex
- group indexorientation
- HORIZONTAL or VERTICAL. It will be ignored if there are groups already.String getNameOf(Component component)
component
.
component
- the component of the document.
DocumentComponent getDocument(String name)
name
.
name
- name
DocumentComponent getDocumentAt(int index)
index
- the index
void activateGroup(IDocumentGroup documentGroup)
documentGroup
- documentGroup to be activatedIDocumentGroup getDocumentGroup(String documentName)
documentName
- the document name.
StringConverter getTitleConverter()
void setTitleConverter(StringConverter titleConverter)
titleConverter
- the new title converter.PopupMenuCustomizer getPopupMenuCustomizer()
void setPopupMenuCustomizer(PopupMenuCustomizer customizer)
customizer
- the popup menu customizer.boolean isGroupsAllowed()
void setGroupsAllowed(boolean groupsAllowed)
groupsAllowed
- true or false.boolean isReorderAllowed()
void setReorderAllowed(boolean reorderAllowed)
reorderAllowed
- true or false.boolean isDocumentOpened(String name)
name
- name of the document
int getDocumentCount()
String getDocumentNameAt(int index)
index
. The order is as the same as the order of when
documents are opened.
index
- document position
getDocument(name)
to get the DocumentComponentString[] getDocumentNames()
int indexOfDocument(String name)
name
- the name of the document.
int groupIndexOfDocument(String name)
name
- the name of the document.
void updateDocument(String documentName)
documentName
- the document name.void renameDocument(String oldName, String newName)
oldName
- old namenewName
- new nameint getDocumentGroupCount()
IDocumentGroup getDocumentGroupAt(int index)
index
- the index.
void floatDocument(String documentName)
documentName
- the document name.void floatDocument(FloatingDocumentContainer floatingContainer, String documentName)
floatingContainer
- the floating container.documentName
- the document name.void dockDocument(String documentName)
documentName
- the name of document that is floating.void dockDocuments(FloatingDocumentContainer container)
container
- the floating container.void closeDocuments(FloatingDocumentContainer container)
container
- the floating container.boolean isDocumentFloating(String documentName)
documentName
- the name of the document
List<FloatingDocumentContainer> getFloatingContainers()
int getSelectedIndexAtGroupIndex(int index)
index
- the index
IndexOutOfBoundsException
- if the index passed in is less than 0 or greater than the number of document
groups.LayoutPersistence getLayoutPersistence()
void setOpenedDocuments(List<DocumentComponent> documentComponents)
documentComponents
- the list of documents.void setDocumentEnabled(String name, boolean enabled)
name
. If you disable a document, the tab for the
document will not be selectable. However if the document is active, it will remain active even you disable it. So
it is recommended to make another document active if you want to disable the active document.
name
- the name of the document.enabled
- true to enable the document and false to disable.void dispose()
boolean isHeavyweightComponentEnabled()
void setHeavyweightComponentEnabled(boolean heavyweightComponentEnabled)
heavyweightComponentEnabled
- true or false.int getFloatingContainerCloseAction()
CLOSE_ACTION_TO_CLOSE
to close all documents inside the floating container, or CLOSE_ACTION_TO_DOCK
to
dock all documents.
void setFloatingContainerCloseAction(int action)
CLOSE_ACTION_TO_CLOSE
to close all documents inside the floating container, or CLOSE_ACTION_TO_DOCK
to
dock all documents.
action
- the close action. Valid values are CLOSE_ACTION_TO_CLOSE
or CLOSE_ACTION_TO_DOCK
.int getFloatingContainerType()
FLOATING_CONTAINER_TYPE_DIALOG
or FLOATING_CONTAINER_TYPE_FRAME
.
void setFloatingContainerType(int floatingContainerType)
FLOATING_CONTAINER_TYPE_DIALOG
, or FLOATING_CONTAINER_TYPE_FRAME
.
floatingContainerType
- the floating container type.
|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |