Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Artifact ID: | 64fbff1f9bdf7eedf51da60c2c460facbfac641ba5f72fc55b8e88cd435a5615 |
---|---|
Page Name: | man-page |
Date: | 2019-11-22 13:52:12 |
Original User: | alex |
Parent: | 7ef9565bb6f76373a956b356ae495bc3527116132bbbdb065578549e27bafcac (diff) |
Next | 93e8fbcaa9384df7d183c8ebba01e2c072c2668ab9114f48385ead1ac6e650a0 |
Man-Page
::ooxml::Default name value ::ooxml::RowColumnToString rowcol ::ooxml::StringToRowColumn name ::ooxml::CalcColumnWidth numberOfCharacters ?maximumDigitWidth? ?pixelPadding? ::ooxml::xl_sheets file ::ooxml::xl_read file args ::ooxml::xl_write args method numberformat args method defaultdatestyle STYLEID method font args method fill args method border args method style args method worksheet name method column sheet args method row sheet args method cell sheet {data {}} args method autofilter sheet indexFrom indexTo method freeze sheet index method presetstyles method presetsheets method write filename ::ooxml::tablelist_to_xl lb args
dashDot | dashDotDot | dashed | dotted | double | hair | medium | mediumDashDot | mediumDashDotDot | mediumDashDotDot | none | slantDashDot | thick | thin
0-65
Aqua | Black | Blue | BlueRomance | Canary | CarnationPink | Citrus | Cream | DarkSlateBlue | DeepSkyBlue | Eucalyptus | Fuchsia | Gray | Green | Karaka | LavenderBlue | LightCoral | LightCyan | LightSkyBlue | Lime | Lipstick | Maroon | Mauve | MediumTurquoise | Myrtle | Navy | NavyBlue | NightRider | Nobel | Olive | OrangePeel | PeachOrange | Portage | PrussianBlue | Purple | Red | RoyalBlue | SaddleBrown | SafetyOrange | Scampi | Silver | TangerineYellow | Teal | White | Yellow | SystemBackground | SystemForeground
RGB
aRGB
0-360
up | down
left | center | right
darkDown | darkGray | darkGrid | darkHorizontal | darkTrellis | darkUp | darkVertical | gray0625 | gray125 | lightDown | lightGray | lightGrid | lightHorizontal | lightTrellis | lightUp | lightVertical | mediumGray | none | solid
top | center | bottom
::ooxml::Default name value
Overwrites default values
- name = path
- (default = ".")
::ooxml::RowColumnToString rowcol
Converts coordinates from numeric row,column (0,0) to Excel style alphanumeric (A1) etc.
return name
::ooxml::StringToRowColumn name
Converts coordinates from Excel style alphanumeric (A1) to numeric row,column (0,0) etc.
return rowcol
::ooxml::CalcColumnWidth numberOfCharacters {maximumDigitWidth 7} {pixelPadding 5}
Calculates the column width based on the number of characters
return width
::ooxml::xl_sheets file
return sheetInformation
::ooxml::xl_read file args
Reads the tables with all the implemented information into an array.
- -valuesonly
- Read data only, no formatting
- -keylist
- Create a key list
- -sheets PATTERN
- Load only the specified table IDs
- -sheetnames PATTERN
- Load only the tables with the specified names
- -datefmt FORMAT
- Date format (default = "%Y-%m-%d %H:%M:%S")
- -as array
- Currently only array output
return workbookData
::ooxml::xl_write constructor args -creator CREATOR
- -creator CREATOR
- Set author name
return class
::ooxml::xl_write method numberformat args
Creates an Excel number format (NUMFMTID) for the current workbook.
- -format FORMAT
- FORMAT can be any Excel format-string
- -general
- Excel general-format
- -date
- Date format
- -time
- Time format
- -datetime
- Date/Time format
- -iso8601
- Date/Time in ISO8601 notation
- -number
- Integer
- -decimal
- Decimal number with 2 decimal places
- -red
- Color red on negative values (can be combined with number and decimal)
- -separator
- Thousand separators (can be combined with number and decimal)
- -fraction
- Fractions
- -scientific
- Scientific numbers
- -percent
- Percentage
- -text|-string
- Text
return NUMFMTID
::ooxml::xl_write method defaultdatestyle STYLEID
Set the style for the default date format (default=0) for the current workbook.
::ooxml::xl_write method font args
Create a FONTID with the following settings for the current workbook.
- -list
- Returns the list of currently defined fonts, in stead of FONTID.
- -name NAME
- (default = "Calibri")
- -family FAMILY
- (defauft = 2)
- -size SIZE
- (default = 12)
- -color COLOR
- (default = "theme 1")
- -scheme SCHEME
- (default = "minor")
- -bold
- -italic
- -underline
- -color COLOR
return FONTID
::ooxml::xl_write method fill args
Create a FILLID with the following settings for the current workbook.
- -list
- Returns the list of currently defined fills, in stead of FILLID.
- -patterntype PATTERNTYPE
- (default = "none")
- -fgcolor COLOR
- -bgcolor COLOR
return FILLID
::ooxml::xl_write method border args
Create a BORDERID with the following settings for the current workbook.
- -list
- Returns the list of currently defined borders, in stead of BORDERID.
- -leftstyle BORDERLINESTYLE
- -leftcolor COLOR
- -rightstyle BORDERLINESTYLE
- -rightcolor COLOR
- -topstyle ORDERLINESTYLE
- -topcolor COLOR
- -bottomstyle BORDERLINESTYLE
- -bottomcolor COLOR
- -diagonalstyle BORDERLINESTYLE
- -diagonalcolor COLOR
- -diagonaldirection DIAGONALDIRECTION
return BORDERID
::ooxml::xl_write method style args
Create a STYLEID with the following settings for the current workbook.
- -list
- Returns the list of currently defined styles, in stead of STYLEID.
- -numfmt NUMFMTID
- -font FONTID
- From method font.
- -fill FILLID
- From method fill.
- -border BORDERID
- From method border.
- -xf XFID
- (default = 0) no method implemented yet
- -horizontal HORIZONTAL
- -vertical VERTICAL
- -rotate DEGREE
return STYLEID
::ooxml::xl_write method worksheet name
Creates a new woksheet for the current workbook.
return sheet
::ooxml::xl_write method column sheet args
Column definitions for the specified worksheet.
- -index INDEX
-
- (autoincrement of column if INDEX not applied)
- -to INDEX
- -width WIDTH
- -style STYLEID
- -bestfit
- -customwidth
- -string
- -nozero
- -calcfit
return column
::ooxml::xl_write method row sheet args
Sets values for the new line or jumps to the line number for the specified worksheet.
- -index INDEX
- (autoincrement of row if INDEX not applied)
- -height HEIGHT
return row
::ooxml::xl_write method cell sheet {data {}} args
- -index INDEX
-
- (autoincrement of column if INDEX not applied)
- -style STYLEID
- -formula FORMULA
- -string
- -nozero
- -globalstyle
- -height HEIGHT
return row,column
::ooxml::xl_write method autofilter sheet indexFrom indexTo
Set autofilter for the specified worksheet.
::ooxml::xl_write method freeze sheet index
Freeze panes for the specified worksheet.
::ooxml::xl_write method presetsheets workbookData
An Excel document read in with ::ooxml::xl_read with the known formats and data preassigned.
::ooxml::xl_write method write filename
Writes the defined Excel document.
::ooxml::tablelist_to_xl lb args
Exporting a tablelist to an Excel file.
- -callback CALLBACK
- default CALLBACK: ::ooxml::tablelist_to_xl_callback
- Callback arguments: spreadsheet sheet maxcol column title width align sortmode hide
- -path PATH
- -file FILENAME
- -creator CREATOR
- -name NAME
- -rootonly
- export tablelist root nodes only
- -addtimestamp
- add timestamp to filename
- -globalstyle
- use / recognize global styles
CALLBACK sample and default:
proc ::ooxml::tablelist_to_xl_callback { spreadsheet sheet maxcol column title width align sortmode hide } { set left 0 set center [$spreadsheet style -horizontal center] set right [$spreadsheet style -horizontal right] set date [$spreadsheet style -numfmt [$spreadsheet numberformat -datetime]] set decimal [$spreadsheet style -numfmt [$spreadsheet numberformat -decimal -red]] set text [$spreadsheet style -numfmt [$spreadsheet numberformat -string]] if {$column == -1} { $spreadsheet defaultdatestyle $date } else { switch -- $align { center { $spreadsheet column $sheet -index $column -style $center } right { $spreadsheet column $sheet -index $column -style $right } default { $spreadsheet column $sheet -index $column -style $left } } } }