Package writer2latex.xhtml

# Class StyleConverterHelper

java.lang.Object
writer2latex.xhtml.StyleConverterHelper

Direct Known Subclasses:
  `HeadingStyleConverter`, `ListStyleConverter`, `PageStyleConverter`, `StyleWithPropertiesConverterHelper`

public abstract class StyleConverterHelper extends Object

This is an abstract base class to convert an OpenDocument style family to CSS2 styles.

## Field Summary

Fields
Modifier and Type
Field
Description
`protected boolean`
`bConvertHard`
`protected boolean`
`bConvertStyles`
`protected int`
`nType`
`protected XhtmlStyleMap`
`styleMap`
`protected ExportNameCollection`
`styleNames`

## Constructor Summary

Constructors
Constructor
Description
`StyleConverterHelper(OfficeReader ofr, XhtmlConfig config, Converter converter, int nType)`
Create a new `StyleConverterHelper`

## Method Summary

Modifier and Type
Method
Description
`protected static void`
`applyDirection(StyleWithProperties style, StyleInfo info)`
Apply the writing direction (ltr or rtl) attribute from a style
`protected static void`
`applyLang(StyleWithProperties style, StyleInfo info)`
Apply language+country from a style
`protected String`
`colScale(String s)`
`abstract String`
`getStyleDeclarations(String sIndent)`
Convert style information for used styles
`abstract OfficeStyleFamily`
`getStyles()`
Get the OpenDocument style family associated with this StyleConverterHelper
`protected String`
`scale(String s)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Field Details

### styleNames

protected ExportNameCollection styleNames

### styleMap

protected XhtmlStyleMap styleMap

### bConvertStyles

protected boolean bConvertStyles

### bConvertHard

protected boolean bConvertHard

### nType

protected int nType

## Constructor Details

### StyleConverterHelper

public StyleConverterHelper(OfficeReader ofr, XhtmlConfig config, Converter converter, int nType)
Create a new `StyleConverterHelper`

Parameters:
  `ofr` - an `OfficeReader` to read style information from
  `config` - the configuration to use
  `converter` - the main `Converter` class
  `nType` - the type of xhtml to use

## Method Details

### scale

protected String scale(String s)

### colScale

protected String colScale(String s)

### applyDirection

protected static void applyDirection(StyleWithProperties style, StyleInfo info)
Apply the writing direction (ltr or rtl) attribute from a style

Parameters:
  `style` - the OpenDocument style to use
  `info` - the `StyleInfo` object to add information to

### applyLang

protected static void applyLang(StyleWithProperties style, StyleInfo info)
Apply language+country from a style

Parameters:
  `style` - the OpenDocument style to use
  `info` - the `StyleInfo` object to add information to

### getStyles

public abstract OfficeStyleFamily getStyles()
Get the OpenDocument style family associated with this StyleConverterHelper

Returns:
  the style family

### getStyleDeclarations

public abstract String getStyleDeclarations(String sIndent)

Convert style information for used styles

Parameters:
  `sIndent` - a String of spaces to add before each line