import org.scilab.modules.gui.uidisplaytree.ScilabUiDisplayTreeBridge;
import org.scilab.modules.gui.uidisplaytree.SimpleUiDisplayTree;
import org.scilab.modules.gui.uidisplaytree.UiDisplayTree;
-import org.scilab.modules.gui.uitable.ScilabUiTableBridge;
-import org.scilab.modules.gui.uitable.SimpleUiTable;
-import org.scilab.modules.gui.uitable.UiTable;
import org.scilab.modules.gui.utils.Position;
import org.scilab.modules.gui.utils.Size;
import org.scilab.modules.gui.window.ScilabWindowBridge;
return ScilabTabBridge.addMember(tab, member);
}
- /**
- * Add a member (dockable element) to a tab and returns the index of this member
- * @param tab the tab which we want to add the UiTable to
- * @param member the UiTable to add
- * @return the position of the UiTable in the member list.
- */
- public static int addMember(Tab tab, UiTable member) {
- return ScilabTabBridge.addMember(tab, member);
- }
-
- /**
- * Remove a UiTable member from a tab
- * @param tab the tab which we want to remove the UiTable from
- * @param member the UiTable to remove
- */
- public static void removeMember(Tab tab, UiTable member) {
- ScilabTabBridge.removeMember(tab, member);
- }
-
public static int addMember(Tab tab, UiDisplayTree member) {
return ScilabTabBridge.addMember(tab, member);
}
}
/**********************/
- /* UiTable Bridge */
- /**********************/
-
- /**
- * Creates a new UiTable
- * @return the created UiTable
- */
- public static SimpleUiTable createUiTable() {
- return ScilabUiTableBridge.createUiTable();
- }
-
- /**
- * Sets the Text of a UiTable
- * @param uiTable the UiTable we want to set the Text of
- * @param newText the Text to set for the UiTable
- */
- public static void setText(UiTable uiTable, String newText) {
- ScilabUiTableBridge.setText(uiTable, newText);
- }
-
- /**
- * Gets the text of an UiTable
- * @param uiTable the UiTable we want to get the text of
- * @return the text of the UiTable
- */
- public static String getText(UiTable uiTable) {
- return ScilabUiTableBridge.getText(uiTable);
- }
-
- /**
- * Draws a Scilab UiTable
- * @param uiTable the UiTable to draw
- * @see org.scilab.modules.ihm.UIElement#draw()
- */
- public static void draw(UiTable uiTable) {
- ScilabUiTableBridge.draw(uiTable);
- }
-
- /**
- * Gets the dimensions (width and height) of a Scilab UiTable
- * @param uiTable the UiTable we want to get the dimensions of
- * @return the size of the uiTable
- * @see org.scilab.modules.ihm.UIElement#getDims()
- */
- public static Size getDims(UiTable uiTable) {
- return ScilabUiTableBridge.getDims(uiTable);
- }
-
- /**
- * Gets the position (X-coordinate and Y-coordinate) of a Scilab uiTable
- * @param uiTable the uiTable we want to get the position of
- * @return the position of the uiTable
- * @see org.scilab.modules.ihm.UIElement#getPosition()
- */
- public static Position getPosition(UiTable uiTable) {
- return ScilabUiTableBridge.getPosition(uiTable);
- }
-
- /**
- * Gets the visibility status of a Scilab UiTable
- * @param uiTable the uiTable we want to get the visiblity status of
- * @return the visibility status of the uiTable (true if the uiTable is visible, false if not)
- * @see org.scilab.modules.ihm.UIElement#isVisible()
- */
- public static boolean isVisible(UiTable uiTable) {
- return ScilabUiTableBridge.isVisible(uiTable);
- }
-
- /**
- * Sets the dimensions (width and height) of a Scilab UiTable
- * @param uiTable the uiTable we want to set the dimensions of
- * @param newSize the size we want to set to the uiTable
- * @see org.scilab.modules.ihm.UIElement#setDims(org.scilab.modules.ihm.utils.Size)
- */
- public static void setDims(UiTable uiTable, Size newSize) {
- ScilabUiTableBridge.setDims(uiTable, newSize);
- }
-
- /**
- * Sets the position (X-coordinate and Y-coordinate) of a Scilab uiTable
- * @param uiTable the uiTable we want to set the position of
- * @param newPosition the position we want to set to the uiTable
- * @see org.scilab.modules.ihm.UIElement#setPosition(org.scilab.modules.ihm.utils.Position)
- */
- public static void setPosition(UiTable uiTable, Position newPosition) {
- ScilabUiTableBridge.setPosition(uiTable, newPosition);
- }
-
- /**
- * Sets the visibility status of a Scilab UiTable
- * @param uiTable the uiTable we want to set the visiblity status of
- * @param newVisibleState the visibility status we want to set to the uiTable (true to set the uiTable visible, false else)
- * @see org.scilab.modules.ihm.UIElement#setVisible(boolean)
- */
- public static void setVisible(UiTable uiTable, boolean newVisibleState) {
- ScilabUiTableBridge.setVisible(uiTable, newVisibleState);
- }
-
- /**
- * Set the Background color of the UiTable
- * @param uiTable the UiTable we want to set the background of
- * @param color the Color
- */
- public static void setBackground(UiTable uiTable, Color color) {
- ScilabUiTableBridge.setBackground(uiTable, color);
- }
-
- /**
- * Get the Background color of the UiTable
- * @param uiTable the UiTable we want to get the background of
- * @return the Color
- */
- public static Color getBackground(UiTable uiTable) {
- return ScilabUiTableBridge.getBackground(uiTable);
- }
-
- /**
- * Set the Foreground color of the UiTable
- * @param uiTable the UiTable we want to set the foreground of
- * @param color the Color
- */
- public static void setForeground(UiTable uiTable, Color color) {
- ScilabUiTableBridge.setForeground(uiTable, color);
- }
-
- /**
- * Get the Foreground color of the UiTable
- * @param uiTable the UiTable we want to get the foreground of
- * @return the Color
- */
- public static Color getForeground(UiTable uiTable) {
- return ScilabUiTableBridge.getForeground(uiTable);
- }
-
- /**
- * Set the font of the UiTable.
- * @param uiTable the UiTable we want to set the font of
- * @param font the font
- */
- public static void setFont(UiTable uiTable, Font font) {
- ScilabUiTableBridge.setFont(uiTable, font);
- }
-
- /**
- * Get the font of the UiTable.
- * @param uiTable the UiTable we want to get the font of
- * @return the font
- */
- public static Font getFont(UiTable uiTable) {
- return ScilabUiTableBridge.getFont(uiTable);
- }
-
- /**
- * Set if the UiTable is enabled or not
- * @param uiTable the UiTable we want to set the status of
- * @param status true if the UiTable is enabled
- */
- public static void setEnabled(UiTable uiTable, boolean status) {
- ScilabUiTableBridge.setEnabled(uiTable, status);
- }
-
- /**
- * Gets the enable status of a UiTable
- * @param uiTable the UiTable we want to get the status of
- * @return the enable status of the UiTable (true if the UiTable is enabled, false if not)
- */
- public static boolean isEnabled(UiTable uiTable) {
- return ScilabUiTableBridge.isEnabled(uiTable);
- }
-
- /**
- * Add a callback to the UiTable
- * @param uiTable the UiTable we want to set the callback of
- * @param callback the Callback to set.
- */
- public static void setCallback(UiTable uiTable, CommonCallBack callback) {
- ScilabUiTableBridge.setCallback(uiTable, callback);
- }
-
- /**
- * Set the horizontal alignment for the UiTable text
- * @param uiTable the UiTable we want to set the alignment of
- * @param alignment the value for the alignment (See ScilabAlignment.java)
- */
- public static void setHorizontalAlignment(UiTable uiTable, String alignment) {
- ScilabUiTableBridge.setHorizontalAlignment(uiTable, alignment);
- }
-
- /**
- * Set the vertical alignment for the UiTable text
- * @param uiTable the UiTable we want to set the alignment of
- * @param alignment the value for the alignment (See ScilabAlignment.java)
- */
- public static void setVerticalAlignment(UiTable uiTable, String alignment) {
- ScilabUiTableBridge.setVerticalAlignment(uiTable, alignment);
- }
-
- /**
- * Set the Relief of the UiTable
- * @param uiTable the UiTable which we want to set the Relief of
- * @param reliefType the type of the relief to set (See ScilabRelief.java)
- */
- public static void setRelief(UiTable uiTable, String reliefType) {
- ScilabUiTableBridge.setRelief(uiTable, reliefType);
- }
-
- /**
- * Delete the UiTable
- * @param uiTable the UiTable to be destroyed
- */
- public static void destroy(UiTable uiTable) {
- ScilabUiTableBridge.destroy(uiTable);
- }
-
- /**
- * Give the focus to the UiTable
- * @param uiTable the UiTable
- */
- public static void requestFocus(UiTable uiTable) {
- ScilabUiTableBridge.requestFocus(uiTable);
- }
-
- /**
- * Sets the column names for uitable
- * @param uiTable the UiTable
- * @param text the String that contains column names delimited by a '|'. Example: 1|2|3|4
- */
- public static void setColnames(UiTable uiTable, String text) {
- ScilabUiTableBridge.setColnames(uiTable, text);
- }
-
- /**
- * Sets the row names for uitable
- * @param uiTable the UiTable
- * @param text the String that contains row names delimited by a '|'. Example: 1|2|3|4
- */
- public static void setRownames(UiTable uiTable, String text) {
- ScilabUiTableBridge.setRownames(uiTable, text);
- }
-
- /**
- * Sets the Data for uitable
- * @param uiTable the UiTable
- * @param text the String that contains row data delimited by a '|'
- * and column data delimited by " ". Example: 1.26 3.47 | a b | d e | a b
- */
- public static void setData(UiTable uiTable, String text) {
- ScilabUiTableBridge.setData(uiTable, text);
- }
-
- /**********************/
/* UiDisplayTree Bridge */
/**********************/