PC SOFT

WINDEV的在线文档

  • Overview
  • Creating a dynamic tab
  • Principle
  • Creating the control
  • Options specific to the control
文档页面当前正在翻译。对于此延迟我们深表歉意。
您可以自愿地帮助我们翻译您想要的文档段落,然后只需通过以下地址与我们联系:info@cn.windev.com
产品
WinDevWebDev-服务器代码WebDev-浏览器代码WinDev Mobile报表和查询
平台
WindowsLinuxWindows MobileWindows PhoneWindows Store appsAndroidAndroid Widget iPhone/iPad
语言
JavaPHPAjax用户代码(MCU)外部语言
数据库
HFSQLHFSQL Client/Server存储过程HF 5.5OLE DBODBC本地访问

Overview
The "Dynamic tab" Tab control is used to display several windows in the same window.

Going from a window to another one is done via tabs, according to an operating mode close to the one of Internet browsers:

  • the tabs can be "moved" outside the main window.
  • the tabs can be reorganized.
  • You have the ability to close some tabs and to open new ones.
Via this type of tabs, the end user can for example:
  • open several windows simultaneously,
  • open several Customer forms simultaneously,
  • display a list of customers and open several Customer forms,
  • keep a customer form opened on a second screen,
  • quickly go from a window to another one without losing its content and the cursor position, ...
Easily propose
Easily propose "browser-like" interfaces

Creating a dynamic tab

Principle

A dynamic tab is based on a standard Tab control.

This tab must contain at least one standard tab pane. This standard tab pane cannot be undocked or handled like the dynamic tab panes.

The dynamic tab panes are added:

  • by programming with 选项卡打开.
  • by the user via the "+" button. In this case, the characteristics of the added dynamic tab pane can be defined in the editor ("Details" tab in the control description) or by programming.

Creating the control

To create a dynamic Tab control:
  1. On the "创建" pane, in the "容器" group, expand "选项卡和关联" and select "Dynamic tab".
  2. Click the position where the control must be created in the window. The control appears in creation mode.
To display the characteristics of the control, select "Description" from the popup menu of the control. The "Details" tab is used to configure the different options of the dynamic tabs.

Other method: To create a Tab control containing static and dynamic tab panes, use the following method:
  1. On the "创建" pane, in the "容器" group, expand "选项卡和关联" and select "Tab".
  2. Click the position where the control must be created in the window. The control appears in creation mode.
  3. Display the description window of the Tab control ("Description" from the popup menu).
  4. In the "Details" tab, check "Enable the features of dynamic tabs". Then, you have the ability to define the different options of the dynamic tabs.
  5. Validate.
Note: You also have the ability to enable the "dynamic" mode on a Tab control via ..MDI选项卡.Note: You also have the ability to enable the "dynamic" mode on a Tab control via ..动态选项卡.

Options specific to the control

The "Details" tab in the window description of the Tab control is used to define the main characteristics of the control. The available options are as follows:
  • With "New" button (+): If this option is checked, a tab containing the "+" sign is displayed after the last tab pane. A click on this tab pane allows the user to create a new dynamic tab pane. This button can also be added by programming with ..带新建按钮.
  • With "Close" button (x): If this option is checked, the created dynamic tab panes include a cross allowing the user to close the tab pane. This button can also be added by programming with ..带关闭按钮.
  • Undockable panes: If this option is checked, the user will be able to undock the dynamic tab panes from the Tab control in order to position them outside the window. This feature can also be defined by programming with ..可分离的窗格.
    Caution: only the dynamic tab panes can be undocked (the ones added by the "+" button or by 选项卡打开). The tab panes described in the editor cannot be undocked.
  • Store the configuration: If this option is checked, the tab configuration performed by the user will be stored. It will be automatically reused during the next opening of the window containing the dynamic tab panes. This feature can also be defined by programming with ..存储配置.
  • Internal window on New button (+): This option allows you to define the internal window that will be used when creating a new tab. The name of this internal window can be modified by programming with ..窗口是否为新建.
    Notes:
    • You can allow the user to define the type of tab that will be created. To do so, specify an internal window proposing the different possible types. The user will only have to select the requested type. See Handling a dynamic tab by programming for more details.
    • When the internal window handled in the dynamic tab is using HFSQL data files, the internal window must use an independent HFSQL context.
  • Default caption of new pane: This option is used to define the default caption that will be used when creating a new dynamic tab pane. This caption can be modified by ..是否新建标签.