Exemplo n.º 1
0
 function &create(&$root, &$pipeline)
 {
     $box = new ListItemBox($root, $pipeline);
     $box->readCSS($pipeline->getCurrentCSSState());
     /**
      * Create text box containing item number
      */
     $css_state =& $pipeline->getCurrentCSSState();
     $css_state->pushState();
     $css_state->setProperty(CSS_COLOR, CSSColor::parse('transparent'));
     $list_style = $css_state->getProperty(CSS_LIST_STYLE);
     $box->str_number_box = TextBox::create(CSSListStyleType::format_number($list_style->type, $css_state->getProperty(CSS_HTML2PS_LIST_COUNTER)) . ". ", 'iso-8859-1', $pipeline);
     $box->str_number_box->baseline = $box->str_number_box->default_baseline;
     $css_state->popState();
     /**
      * Create nested items
      */
     $box->create_content($root, $pipeline);
     return $box;
 }
Exemplo n.º 2
0
 function &create(&$root, &$pipeline)
 {
     $box = new ListItemBox($root, $pipeline);
     $box->create_content($root, $pipeline);
     return $box;
 }