Sheetbar"
From Documentation
m |
(→I18N) |
||
Line 21: | Line 21: | ||
====I18N==== | ====I18N==== | ||
− | Each button/menuitem map to a key, developer could | + | Each button/menuitem map to a key, developer could browse all I18 keys by <javadoc directory="zss" method="getLabelKeys">org.zkoss.zss.ui.Action</javadoc> |
Here is partial keys for sheetbar | Here is partial keys for sheetbar |
Revision as of 07:29, 9 April 2012
Purpose
ZK Spreadsheet provide sheetbar to perform sheet actions, such as select sheet, add sheet, delete sheet etc...
Show Sheetbar
Use Spreadsheet.setShowSheetbar to show sheetbar.
Add Sheet
The new sheet name prefix use Sheet, developer could change it by use I18N key zss.sheet
I18N
Each button/menuitem map to a key, developer could browse all I18 keys by Action.getLabelKeys
Here is partial keys for sheetbar
Action | I18 Key |
---|---|
Sheet | zss.sheet |
Add Sheet | zss.addSheet |
Delete Sheet | zss.deleteSheet |
Rename Sheet | zss.renameSheet |
Move Sheet Left | zss.moveSheetLeft |
Move Sheet Right | zss.moveSheetRight |
Protect Sheet | zss.protectSheet |
Refer to sample i3-label.properties
ZUML
Here is a sample example ZUL file
<zk>
<window vflex="1" width="100%" apply="org.zkoss.zssessentials.config.SheetbarComposer">
<button id="toggleSheetbar" label="Toggle sheetbar"/>
<spreadsheet showSheetbar="true"
id="spreadsheet" vflex="true" width="100%"
src="/WEB-INF/excel/config/ZSS-demo_sample.xlsx" maxcolumns="40" maxrows="200"
></spreadsheet>
</window>
</zk>
View complete source of ZUML sheetbar.zul
Composer
The composer use Spreadsheet.setShowSheetbar to show or hide sheetbar.
public void onClick$toggleSheetbar() {
boolean toggle = !spreadsheet.isShowSheetbar();
spreadsheet.setShowSheetbar(toggle);
}
See the full source code for Composer here
Version History
Version | Date | Content |
---|---|---|
2.3.0 | April, 2012 | Sheetbar |
All source code listed in this book is at Github.