2.4. Example of a property with keywords

The value of the property border-top-width can be set to a width, but it can also be indicated by one of the keywords thin, medium and thick. The width values to which these keywords correspond are by default set by the implementation. When the property maker is constructed in FOPropertyMapping, it gets a hash map of keyword values.

 this = "org.apache.fop.fo.properties.BorderWidthPropertyMaker@1cf4a2c"
 this.propId = 55
 this.keywords = "{medium=1pt, thin=0.5pt, thick=2pt}"
}

The method checkValueKeywords returns the mapped value: value = "1pt". Subsequently a property value object is created as if that value had been specified.

  [1] org.apache.fop.fo.properties.PropertyMaker.checkValueKeywords (PropertyMaker.java:499)
  [2] org.apache.fop.fo.properties.PropertyMaker.make (PropertyMaker.java:387)
  [3] org.apache.fop.fo.PropertyList.convertAttributeToProperty (PropertyList.java:418)
  [4] org.apache.fop.fo.PropertyList.addAttributesToList (PropertyList.java:374)
  [5] org.apache.fop.fo.FObj.addProperties (FObj.java:133)