|
Moodle
2.2.1
http://www.collinsharper.com
|

Public Member Functions | |
| __construct (moodle_page $page, $target) | |
| render (renderable $widget) | |
| add_action_handler (component_action $action, $id=null) | |
| has_started () | |
| pix_url ($imagename, $component= 'moodle') | |
Static Public Member Functions | |
| static | prepare_classes ($classes) |
Protected Attributes | |
| $opencontainers | |
| $page | |
| $target | |
Simple base class for Moodle renderers.
Tracks the xhtml_container_stack to use, which is passed in in the constructor.
Also has methods to facilitate generating HTML output.
Definition at line 43 of file outputrenderers.php.
| __construct | ( | moodle_page $ | page, |
| $ | target | ||
| ) |
Constructor
| moodle_page | $page | the page we are doing output for. |
| string | $target | one of rendering target constants |
Reimplemented in core_renderer, plugin_renderer_base, and core_course_renderer.
Definition at line 56 of file outputrenderers.php.
| add_action_handler | ( | component_action $ | action, |
| $ | id = null |
||
| ) |
Adds JS handlers needed for event execution for one html element id
| component_action | $actions | |
| string | $id |
Definition at line 81 of file outputrenderers.php.


| has_started | ( | ) |
Have we started output yet?
Definition at line 93 of file outputrenderers.php.

| pix_url | ( | $ | imagename, |
| $ | component = 'moodle' |
||
| ) |
Return the moodle_url for an image. The exact image location and extension is determined automatically by searching for gif|png|jpg|jpeg, please note there can not be diferent images with the different extension. The imagename is for historical reasons a relative path name, it may be changed later for core images. It is recommended to not use subdirectories in plugin and theme pix directories.
There are three types of images: 1/ theme images - stored in theme/mytheme/pix/, use component 'theme' 2/ core images - stored in /pix/, overridden via theme/mytheme/pix_core/ 3/ plugin images - stored in mod/mymodule/pix, overridden via theme/mytheme/pix_plugins/mod/mymodule/, example: pix_url('comment', 'mod_glossary')
| string | $imagename | the pathname of the image |
| string | $component | full plugin name (aka component) or 'theme' |
Definition at line 132 of file outputrenderers.php.

| static prepare_classes | ( | $ | classes | ) | [static] |
Given an array or space-separated list of classes, prepares and returns the HTML class attribute value
| mixed | $classes | Space-separated string or array of classes |
Definition at line 102 of file outputrenderers.php.

| render | ( | renderable $ | widget | ) |
Returns rendered widget.
| renderable | $widget | instance with renderable interface |
Reimplemented in plugin_renderer_base.
Definition at line 67 of file outputrenderers.php.

$opencontainers [protected] |
Definition at line 45 of file outputrenderers.php.
$page [protected] |
Definition at line 47 of file outputrenderers.php.
$target [protected] |
Definition at line 49 of file outputrenderers.php.