Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Artifact ID: | 36d9e45837d93e1b1f0898dfa4c1645555d7d76b529c6f84ea0562d4dc92bf12 |
---|---|
Page Name: | man-page |
Date: | 2019-08-06 21:03:15 |
Original User: | alex |
Parent: | 60a5f4ecd128d3ac02ad6d315246664d6a20c0f44072524ae373075c9568e7b6 (diff) |
Next | 7ef9565bb6f76373a956b356ae495bc3527116132bbbdb065578549e27bafcac |
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 ::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 } } } }