當前位置: 首頁>>代碼示例>>PHP>>正文


PHP GenericFormattedBox::show方法代碼示例

本文整理匯總了PHP中GenericFormattedBox::show方法的典型用法代碼示例。如果您正苦於以下問題:PHP GenericFormattedBox::show方法的具體用法?PHP GenericFormattedBox::show怎麽用?PHP GenericFormattedBox::show使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在GenericFormattedBox的用法示例。


在下文中一共展示了GenericFormattedBox::show方法的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: show

 function show(&$driver)
 {
     // Now set the baseline of a button box to align it vertically when flowing isude the
     // text line
     $this->default_baseline = $this->content[0]->baseline + $this->get_extra_top();
     $this->baseline = $this->content[0]->baseline + $this->get_extra_top();
     /**
      * If we're rendering the interactive form, the field content should not be rendered
      */
     global $g_config;
     if ($g_config['renderforms']) {
         /**
          * Render background/borders only
          */
         $status = GenericFormattedBox::show($driver);
         /**
          * @todo encoding name?
          * @todo font name?
          * @todo check if font is embedded for PDFLIB
          */
         $driver->field_text($this->get_left_padding(), $this->get_top_padding(), $this->get_width() + $this->get_padding_left() + $this->get_padding_right(), $this->get_height(), $this->_value, $this->_field_name);
     } else {
         /**
          * Render everything, including content
          */
         $status = GenericContainerBox::show($driver);
     }
     return $status;
 }
開發者ID:VUW-SIM-FIS,項目名稱:emiemi,代碼行數:29,代碼來源:box.input.text.php

示例2: show_field

 function show_field(&$driver)
 {
     if (is_null(GenericFormattedBox::show($driver))) {
         return null;
     }
     $driver->field_select($this->get_left_padding(), $this->get_top_padding(), $this->get_width() + $this->get_padding_left() + $this->get_padding_right(), $this->get_height(), $this->_name, $this->_value, $this->_options);
     return true;
 }
開發者ID:isantiago,項目名稱:foswiki,代碼行數:8,代碼來源:box.select.php

示例3: show

 function show(&$driver)
 {
     /**
      * If we're rendering the interactive form, the field content should not be rendered
      */
     global $g_config;
     if ($g_config['renderforms']) {
         $status = GenericFormattedBox::show($driver);
         $driver->field_multiline_text($this->get_left_padding(), $this->get_top_padding(), $this->get_width() + $this->get_padding_left() + $this->get_padding_right(), $this->get_height() + $this->get_padding_top() + $this->get_padding_bottom(), $this->_value, $this->_field_name);
     } else {
         $status = GenericContainerBox::show($driver);
     }
     return $status;
 }
開發者ID:isantiago,項目名稱:foswiki,代碼行數:14,代碼來源:box.input.textarea.php

示例4: show

 function show(&$driver)
 {
     // draw generic box
     GenericFormattedBox::show($driver);
     // Check if "designer" set the height or width of this image to zero; in this there will be no reason
     // in drawing the image at all
     //
     if ($this->get_width() < EPSILON || $this->get_height() < EPSILON || is_null($this->image->_handle)) {
         return true;
     }
     $driver->image_scaled($this->image, $this->get_left(), $this->get_bottom(), $this->get_width() / $this->image->sx(), $this->get_height() / $this->image->sy());
     $strategy =& new StrategyLinkRenderingNormal();
     $strategy->apply($this, $driver);
     return true;
 }
開發者ID:CartworksPlatform,項目名稱:cartworksplatform,代碼行數:15,代碼來源:box.img.php

示例5: show_fixed

 /** 
  * Render current fixed-positioned container box using the specified output method. Unlike
  * the 'show' method, there's no check if current page viewport contains current element, as
  * fixed-positioned may be drawn on the page margins, outside the viewport.
  *
  * @param OutputDriver $driver The output driver object
  * 
  * @return Boolean flag indicating the success or 'null' value in case of critical rendering 
  * error
  *
  * @see GenericContainerBox::show()
  * 
  * @todo the 'show' and 'show_fixed' method code are almost the same except the child element 
  * method called in the inner loop; also, no check is done if current viewport contains this element,
  * thus sllowinf printing data on page margins, where no data should be printed normally
  * I suppose some more generic method containing the common code should be made.
  */
 function show_fixed(&$driver)
 {
     GenericFormattedBox::show($driver);
     $overflow = $this->getCSSProperty(CSS_OVERFLOW);
     /**
      * Sometimes the content may overflow container boxes. This situation arise, for example,
      * for relative-positioned child boxes, boxes having constrained height and in some
      * other cases. If the container box does not have CSS 'overflow' property 
      * set to 'visible' value, the content should be visually clipped using container box
      * padding area.
      */
     if ($overflow !== OVERFLOW_VISIBLE) {
         // Save graphics state (of course, BEFORE the clipping area will be set)
         $driver->save();
         $this->_setupClip($driver);
     }
     /**
      * Render child elements
      */
     $size = count($this->content);
     for ($i = 0; $i < $size; $i++) {
         /**
          * We'll check the visibility property here
          * Reason: all boxes (except the top-level one) are contained in some other box, 
          * so every box will pass this check. The alternative is to add this check into every
          * box class show member.
          *
          * The only exception of absolute positioned block boxes which are drawn separately;
          * their show method is called explicitly; the similar check should be performed there
          */
         $child =& $this->content[$i];
         if ($child->getCSSProperty(CSS_VISIBILITY) === VISIBILITY_VISIBLE) {
             // Fixed-positioned blocks are displayed separately;
             // If we call them now, they will be drawn twice
             if ($child->getCSSProperty(CSS_POSITION) != POSITION_FIXED) {
                 if (is_null($child->show_fixed($driver))) {
                     return null;
                 }
             }
         }
     }
     /** 
      * Restore previous clipping mode, if it have been modified for non-'overflow: visible' 
      * box.
      */
     if ($overflow !== OVERFLOW_VISIBLE) {
         $driver->restore();
     }
     return true;
 }
開發者ID:emildev35,項目名稱:processmaker,代碼行數:67,代碼來源:box.container.php

示例6: show

 function show(&$viewport)
 {
     // draw generic box
     GenericFormattedBox::show($viewport);
     // Check if "designer" set the height or width of this image to zero; in this there will be no reason
     // in drawing the image at all
     //
     if ($this->get_width() < EPSILON || $this->get_height() < EPSILON) {
         return true;
     }
     $viewport->image_scaled($this->image, $this->get_left(), $this->get_bottom(), $this->get_width() / imagesx($this->image), $this->get_height() / imagesy($this->image));
     return true;
 }
開發者ID:raimundlandig,項目名稱:winkel.de-DEV,代碼行數:13,代碼來源:box.img.php


注:本文中的GenericFormattedBox::show方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。