<?php

/**
 * ODTParagraphStyle: class for ODT paragraph styles.
 *
 * @license    GPL 2 (http://www.gnu.org/licenses/gpl.html)
 * @author LarsDW223
 */
require_once DOKU_PLUGIN . 'odt/ODT/XMLUtil.php';
require_once 'ODTStyle.php';
ODTStyleStyle::register('ODTParagraphStyle');
/**
 * The ODTParagraphStyle class
 */
class ODTParagraphStyle extends ODTStyleStyle
{
    static $paragraph_fields = array('line-height' => array('fo:line-height', 'paragraph', true), 'line-height-at-least' => array('style:line-height-at-least', 'paragraph', true), 'line-spacing' => array('style:line-spacing', 'paragraph', true), 'font-independent-line-spacing' => array('style:font-independent-line-spacing', 'paragraph', true), 'text-align' => array('fo:text-align', 'paragraph', true), 'text-align-last' => array('fo:text-align-last', 'paragraph', true), 'justify-single-word' => array('style:justify-single-word', 'paragraph', true), 'keep-together' => array('fo:keep-together', 'paragraph', true), 'widows' => array('fo:widows', 'paragraph', true), 'orphans' => array('fo:orphans', 'paragraph', true), 'tab-stop-distance' => array('style:tab-stop-distance', 'paragraph', true), 'hyphenation-keep' => array('fo:hyphenation-keep', 'paragraph', true), 'hyphenation-ladder-count' => array('fo:hyphenation-ladder-count', 'paragraph', true), 'register-true' => array('style:register-true', 'paragraph', true), 'text-indent' => array('fo:text-indent', 'paragraph', true), 'auto-text-indent' => array('style:auto-text-indent', 'paragraph', true), 'margin' => array('fo:margin', 'paragraph', true), 'margin-top' => array('fo:margin-top', 'paragraph', true), 'margin-right' => array('fo:margin-right', 'paragraph', true), 'margin-bottom' => array('fo:margin-bottom', 'paragraph', true), 'margin-left' => array('fo:margin-left', 'paragraph', true), 'break-before' => array('fo:break-before', 'paragraph', true), 'break-after' => array('fo:break-after', 'paragraph', true), 'background-color' => array('fo:background-color', 'paragraph', true), 'border' => array('fo:border', 'paragraph', true), 'border-top' => array('fo:border-top', 'paragraph', true), 'border-right' => array('fo:border-right', 'paragraph', true), 'border-bottom' => array('fo:border-bottom', 'paragraph', true), 'border-left' => array('fo:border-left', 'paragraph', true), 'border-line-width' => array('style:border-line-width', 'paragraph', true), 'border-line-width-top' => array('style:border-line-width-top', 'paragraph', true), 'border-line-width-bottom' => array('style:border-line-width-bottom', 'paragraph', true), 'border-line-width-left' => array('style:border-line-width-left', 'paragraph', true), 'border-line-width-right' => array('style:border-line-width-right', 'paragraph', true), 'join-border' => array('style:join-border', 'paragraph', true), 'padding' => array('fo:padding', 'paragraph', true), 'padding-top' => array('fo:padding-top', 'paragraph', true), 'padding-bottom' => array('fo:padding-bottom', 'paragraph', true), 'padding-left' => array('fo:padding-left', 'paragraph', true), 'padding-right' => array('fo:padding-right', 'paragraph', true), 'shadow' => array('style:shadow', 'paragraph', true), 'keep-with-next' => array('fo:keep-with-next', 'paragraph', true), 'number-lines' => array('text:number-lines', 'paragraph', true), 'line-number' => array('text:line-number', 'paragraph', true), 'text-autospace' => array('style:text-autospace', 'paragraph', true), 'punctuation-wrap' => array('style:punctuation-wrap', 'paragraph', true), 'line-break' => array('style:line-break', 'paragraph', true), 'vertical-align' => array('style:vertical-align', 'paragraph', true), 'writing-mode' => array('style:writing-mode', 'paragraph', true), 'writing-mode-automatic' => array('style:writing-mode-automatic', 'paragraph', true), 'snap-to-layout-grid' => array('style:snap-to-layout-grid', 'paragraph', true), 'page-number' => array('style:page-number', 'paragraph', true), 'background-transparency' => array('style:background-transparency', 'paragraph', true));
    // Additional fields for child element tab-stop.
    static $tab_stop_fields = array('style-position' => array('style:position', 'tab-stop', true), 'style-type' => array('style:type', 'tab-stop', true), 'style-leader-type' => array('style:leader-type', 'tab-stop', true), 'style-leader-style' => array('style:leader-style', 'tab-stop', true), 'style-leader-width' => array('style:leader-width', 'tab-stop', true), 'style-leader-color' => array('style:leader-color', 'tab-stop', true), 'style-leader-text' => array('style:leader-text', 'tab-stop', true));
    protected $style_properties = array();
    protected $text_properties = array();
    protected $tab_stops = array();
    /**
     * Constructor.
     */
    public function __construct()
    {
        parent::__construct();
    }
    /**
     * Set style properties by importing values from a properties array.
<?php

/**
 * ODTTableRowStyle: class for ODT table row styles.
 *
 * @license    GPL 2 (http://www.gnu.org/licenses/gpl.html)
 * @author LarsDW223
 */
require_once DOKU_INC . 'lib/plugins/odt/ODT/XMLUtil.php';
require_once 'ODTStyle.php';
ODTStyleStyle::register('ODTTableRowStyle');
/**
 * The ODTTableRowStyle class
 */
class ODTTableRowStyle extends ODTStyleStyle
{
    static $table_row_fields = array('row-height' => array('style:row-height', 'table-row', true), 'min-row-height' => array('style:min-row-height', 'table-row', true), 'use-optimal-row-height' => array('style:use-optimal-row-height', 'table-row', true), 'background-color' => array('fo:background-color', 'table-row', true), 'background-color' => array('fo:background-color', 'table-row', true), 'break-before' => array('fo:break-before', 'table-row', true), 'break-after' => array('fo:break-after', 'table-row', true), 'keep-together' => array('fo:keep-together', 'table-row', true), 'repeat' => array('style:repeat', 'table-row-background-image', true), 'position' => array('style:position', 'table-row-background-image', true), 'style:filter-name' => array('style:filter-name', 'table-row-background-image', true), 'opacity' => array('draw:opacity', 'table-row-background-image', true), 'type' => array('xlink:type', 'table-row-background-image', true), 'href' => array('xlink:href', 'table-row-background-image', true), 'show' => array('xlink:show', 'table-row-background-image', true), 'actuate' => array('xlink:actuate', 'table-row-background-image', true), 'binary-data' => array('office:binary-data', 'table-row-background-image', true), 'base64Binary' => array('base64Binary', 'table-row-background-image', true));
    /**
     * Constructor.
     */
    public function __construct()
    {
        parent::__construct();
    }
    /**
     * Set style properties by importing values from a properties array.
     * Properties might be disabled by setting them in $disabled.
     * The style must have been previously created.
     *
     * @param  $properties Properties to be imported
     * @param  $disabled Properties to be ignored
<?php

/**
 * ODTTableColumnStyle: class for ODT table column styles.
 *
 * @license    GPL 2 (http://www.gnu.org/licenses/gpl.html)
 * @author LarsDW223
 */
require_once DOKU_INC . 'lib/plugins/odt/ODT/XMLUtil.php';
require_once 'ODTStyle.php';
ODTStyleStyle::register('ODTTableColumnStyle');
/**
 * The ODTTableColumnStyle class
 */
class ODTTableColumnStyle extends ODTStyleStyle
{
    static $table_column_fields = array('column-width' => array('style:column-width', 'table-column', true), 'rel-column-width' => array('style:rel-column-width', 'table-column', true), 'use-optimal-column-width' => array('style:use-optimal-column-width', 'table-column', true), 'use-optimal-column-width' => array('style:use-optimal-column-width', 'table-column', true), 'break-before' => array('fo:break-before', 'table-column', true), 'break-after' => array('fo:break-after', 'table-column', true));
    /**
     * Constructor.
     */
    public function __construct()
    {
        parent::__construct();
    }
    /**
     * Set style properties by importing values from a properties array.
     * Properties might be disabled by setting them in $disabled.
     * The style must have been previously created.
     *
     * @param  $properties Properties to be imported
     * @param  $disabled Properties to be ignored
Ejemplo n.º 4
0
<?php

/**
 * ODTTextStyle: class for ODT text styles.
 *
 * @license    GPL 2 (http://www.gnu.org/licenses/gpl.html)
 * @author LarsDW223
 */
require_once DOKU_PLUGIN . 'odt/ODT/XMLUtil.php';
require_once 'ODTStyle.php';
ODTStyleStyle::register('ODTTextStyle');
/**
 * The ODTTextStyle class
 */
class ODTTextStyle extends ODTStyleStyle
{
    static $text_fields = array('padding' => array('fo:padding', 'text', true), 'padding-top' => array('fo:padding-top', 'text', true), 'padding-right' => array('fo:padding-right', 'text', true), 'padding-bottom' => array('fo:padding-bottom', 'text', true), 'padding-left' => array('fo:padding-left', 'text', true), 'border' => array('fo:border', 'text', true), 'border-top' => array('fo:border-top', 'text', true), 'border-right' => array('fo:border-right', 'text', true), 'border-bottom' => array('fo:border-bottom', 'text', true), 'border-left' => array('fo:border-left', 'text', true), 'color' => array('fo:color', 'text', true), 'background-color' => array('fo:background-color', 'text', true), 'background-image' => array('fo:background-image', 'text', true), 'font-style' => array('fo:font-style', 'text', true), 'font-style-asian' => array('style:font-style-asian', 'text', true), 'font-style-complex' => array('style:font-style-complex', 'text', true), 'font-weight' => array('fo:font-weight', 'text', true), 'font-weight-asian' => array('style:font-weight-asian', 'text', true), 'font-weight-complex' => array('style:font-weight-complex', 'text', true), 'font-size' => array('fo:font-size', 'text', true), 'font-size-asian' => array('style:font-size-asian', 'text', true), 'font-size-complex' => array('style:font-size-complex', 'text', true), 'font-family' => array('fo:font-family', 'text', true), 'font-family-asian' => array('style:font-family-asian', 'text', true), 'font-family-complex' => array('style:font-family-complex', 'text', true), 'font-variant' => array('fo:font-variant', 'text', true), 'letter-spacing' => array('fo:letter-spacing', 'text', true), 'vertical-align' => array('style:vertical-align', 'text', true), 'display' => array('text:display', 'text', true), 'lang' => array('fo:language', 'text', true), 'lang-asian' => array('style:language-asian', 'text', true), 'lang-complex' => array('style:language-complex', 'text', true), 'country' => array('fo:country', 'text', true), 'country-asian' => array('style:country-asian', 'text', true), 'country-complex' => array('style:country-complex', 'text', true), 'text-transform' => array('fo:text-transform', 'text', true), 'use-window-font-color' => array('style:use-window-font-color', 'text', true), 'text-outline' => array('style:text-outline', 'text', true), 'text-line-through-type' => array('style:text-line-through-type', 'text', true), 'text-line-through-style' => array('style:text-line-through-style', 'text', true), 'text-line-through-width' => array('style:text-line-through-width', 'text', true), 'text-line-through-color' => array('style:text-line-through-color', 'text', true), 'text-line-through-text' => array('style:text-line-through-text', 'text', true), 'text-line-through-text-style' => array('style:text-line-through-text-style', 'text', true), 'text-position' => array('style:text-position', 'text', true), 'font-name' => array('style:font-name', 'text', true), 'font-name-asian' => array('style:font-name-asian', 'text', true), 'font-name-complex' => array('style:font-name-complex', 'text', true), 'font-family-generic' => array('style:font-family-generic', 'text', true), 'font-family-generic-asian' => array('style:font-family-generic-asian', 'text', true), 'font-family-generic-complex' => array('style:font-family-generic-complex', 'text', true), 'font-style-name' => array('style:font-style-name', 'text', true), 'font-style-name-asian' => array('style:font-style-name-asian', 'text', true), 'font-style-name-complex' => array('style:font-style-name-complex', 'text', true), 'font-pitch' => array('style:font-pitch', 'text', true), 'font-pitch-asian' => array('style:font-pitch-asian', 'text', true), 'font-pitch-complex' => array('style:font-pitch-complex', 'text', true), 'font-charset' => array('style:font-charset', 'text', true), 'font-charset-asian' => array('style:font-charset-asian', 'text', true), 'font-charset-complex' => array('style:font-charset-complex', 'text', true), 'font-size-rel' => array('style:font-size-rel', 'text', true), 'font-size-rel-asian' => array('style:font-size-rel-asian', 'text', true), 'font-size-rel-complex' => array('style:font-size-rel-complex', 'text', true), 'script-type' => array('style:script-type', 'text', true), 'script' => array('fo:script', 'text', true), 'script-asian' => array('style:script-asian', 'text', true), 'script-complex' => array('style:script-complex', 'text', true), 'rfc-language-tag' => array('style:rfc-language-tag', 'text', true), 'rfc-language-tag-asian' => array('style:rfc-language-tag-asian', 'text', true), 'rfc-language-tag-complex' => array('style:rfc-language-tag-complex', 'text', true), 'rfc-language-tag-complex' => array('style:rfc-language-tag-complex', 'text', true), 'font-relief' => array('style:font-relief', 'text', true), 'text-shadow' => array('fo:text-shadow', 'text', true), 'text-underline-type' => array('style:text-underline-type', 'text', true), 'text-underline-style' => array('style:text-underline-style', 'text', true), 'text-underline-width' => array('style:text-underline-width', 'text', true), 'text-underline-color' => array('style:text-underline-color', 'text', true), 'text-overline-type' => array('style:text-overline-type', 'text', true), 'text-overline-style' => array('style:text-overline-style', 'text', true), 'text-overline-width' => array('style:text-overline-width', 'text', true), 'text-overline-color' => array('style:text-overline-color', 'text', true), 'text-overline-mode' => array('style:text-overline-mode', 'text', true), 'text-underline-mode' => array('style:text-underline-mode', 'text', true), 'text-line-through-mode' => array('style:text-line-through-mode', 'text', true), 'letter-kerning' => array('style:letter-kerning', 'text', true), 'text-blinking' => array('style:text-blinking', 'text', true), 'text-combine' => array('style:text-combine', 'text', true), 'text-combine-start-char' => array('style:text-combine-start-char', 'text', true), 'text-combine-end-char' => array('style:text-combine-end-char', 'text', true), 'text-emphasize' => array('style:text-emphasize', 'text', true), 'text-scale' => array('style:text-scale', 'text', true), 'text-rotation-angle' => array('style:text-rotation-angle', 'text', true), 'text-rotation-scale' => array('style:text-rotation-scale', 'text', true), 'hyphenate' => array('fo:hyphenate', 'text', true), 'hyphenation-remain-char-count' => array('fo:hyphenation-remain-char-count', 'text', true), 'hyphenation-push-char-count' => array('fo:hyphenation-push-char-count', 'text', true), 'condition' => array('text:condition', 'text', true));
    /**
     * Constructor.
     */
    public function __construct()
    {
        parent::__construct();
    }
    /**
     * Set style properties by importing values from a properties array.
     * Properties might be disabled by setting them in $disabled.
     * The style must have been previously created.
     *
     * @param  $properties Properties to be imported
     * @param  $disabled Properties to be ignored
<?php

/**
 * ODTTableCellStyle: class for ODT table cell styles.
 *
 * @license    GPL 2 (http://www.gnu.org/licenses/gpl.html)
 * @author LarsDW223
 */
require_once DOKU_INC . 'lib/plugins/odt/ODT/XMLUtil.php';
require_once 'ODTStyle.php';
ODTStyleStyle::register('ODTTableCellStyle');
/**
 * The ODTTableCellStyle class
 */
class ODTTableCellStyle extends ODTStyleStyle
{
    static $table_cell_fields = array('vertical-align' => array('style:vertical-align', 'table-cell', true), 'text-align-source' => array('style:text-align-source', 'table-cell', true), 'direction' => array('style:direction', 'table-cell', true), 'glyph-orientation-vertical' => array('style:glyph-orientation-vertical', 'table-cell', true), 'writing-mode' => array('style:writing-mode', 'table-cell', true), 'shadow' => array('style:shadow', 'table-cell', true), 'background-color' => array('fo:background-color', 'table-cell', true), 'background-color' => array('fo:background-color', 'table-cell', true), 'border' => array('fo:border', 'table-cell', true), 'border-top' => array('fo:border-top', 'table-cell', true), 'border-right' => array('fo:border-right', 'table-cell', true), 'border-bottom' => array('fo:border-bottom', 'table-cell', true), 'border-left' => array('fo:border-left', 'table-cell', true), 'diagonal-tl-br' => array('style:diagonal-tl-br', 'table-cell', true), 'diagonal-tl-br-widths' => array('style:diagonal-tl-br-widths', 'table-cell', true), 'diagonal-bl-tr' => array('style:diagonal-bl-tr', 'table-cell', true), 'diagonal-bl-tr-widths' => array('style:diagonal-bl-tr-widths', 'table-cell', true), 'border-line-width' => array('style:border-line-width', 'table-cell', true), 'border-line-width-top' => array('style:border-line-width-top', 'table-cell', true), 'border-line-width-bottom' => array('style:border-line-width-bottom', 'table-cell', true), 'border-line-width-left' => array('style:border-line-width-left', 'table-cell', true), 'border-line-width-right' => array('style:border-line-width-right', 'table-cell', true), 'padding' => array('fo:padding', 'table-cell', true), 'padding-top' => array('fo:padding-top', 'table-cell', true), 'padding-right' => array('fo:padding-right', 'table-cell', true), 'padding-bottom' => array('fo:padding-bottom', 'table-cell', true), 'padding-left' => array('fo:padding-left', 'table-cell', true), 'wrap-option' => array('fo:wrap-option', 'table-cell', true), 'rotation-angle' => array('style:rotation-angle', 'table-cell', true), 'rotation-align' => array('style:rotation-align', 'table-cell', true), 'cell-protect' => array('style:cell-protect', 'table-cell', true), 'print-content' => array('style:print-content', 'table-cell', true), 'decimal-places' => array('style:decimal-places', 'table-cell', true), 'repeat-content' => array('style:repeat-content', 'table-cell', true), 'shrink-to-fit' => array('style:shrink-to-fit', 'table-cell', true), 'repeat' => array('style:repeat', 'table-cell-background-image', true), 'position' => array('style:position', 'table-cell-background-image', true), 'style:filter-name' => array('style:filter-name', 'table-cell-background-image', true), 'opacity' => array('draw:opacity', 'table-cell-background-image', true), 'type' => array('xlink:type', 'table-cell-background-image', true), 'href' => array('xlink:href', 'table-cell-background-image', true), 'show' => array('xlink:show', 'table-cell-background-image', true), 'actuate' => array('xlink:actuate', 'table-cell-background-image', true), 'binary-data' => array('office:binary-data', 'table-cell-background-image', true), 'base64Binary' => array('base64Binary', 'table-cell-background-image', true));
    /**
     * Constructor.
     */
    public function __construct()
    {
        parent::__construct();
    }
    /**
     * Set style properties by importing values from a properties array.
     * Properties might be disabled by setting them in $disabled.
     * The style must have been previously created.
     *
     * @param  $properties Properties to be imported
     * @param  $disabled Properties to be ignored