$this->cchunk["fieldsynopsis"]["modifier"] was not set for atrributes due to the early return, but this value is needed in order to be able to decide if the fieldsynopsis refers to a constant or a property at d7f7004639/phpdotnet/phd/Package/Generic/XHTML.php (L1608)
Add rendering support for DocBook's <packagesynopsis> and <package>
elements so that namespaced PHP classes and enums can display a proper
`namespace X;` declaration above the class/enum synopsis.
This allows us to set 'interactive' annotations on books, sets, and chapters to
signal to the WASM code runner that examples in these areas can be run.
The WASM code runner also checks for the 'non-interactive' annotation and
selectively disables running code for that example.
- Move error handling code into a class and remove PhD message output handling from it.
- Introduce a new class to handle PhD message output.
- Make the implicit dependency on the output functionality of classes explicit.
- Update PEAR package.xml.
- Fix tests.
- Use proper variadic parameters
- Use class constants
- Use first-class callable syntax
---------
Co-authored-by: haszi <haszika80@gmail.com>
Add links to constants with replaceable tags by processing them when the constant tag is being closed.
Add a test.
Co-authored-by: haszi <haszika80@gmail.com>
* Add Config as a dependency to Format and all it subclasses
* Inject Config into every Format subclass at instantiation
---------
Co-authored-by: haszi <haszika80@gmail.com>
Replace static example element counter with class properties in Index and generic XHTML.
Add tests.
Refactor TestRender so that it can render multiple formats.
Co-authored-by: haszi <haszika80@gmail.com>
* Add rendering support for new class and exception markup
Add rendering support for new class and exception markup in the PHP package.
Add tests for the old and the new class and exception markup.
* Add indexing support for new class and exception markup
* Make PhD aware of the current class or exception name when using the new markup
When a reference element has the appropriate roles, store the name of the current class or exception. If this is not done, PhD will generate links to the class even from the class's own synopsis page.
* Fix code formatting differences in screen elements
* Add tests comparing old and new markup rendering output
---------
Co-authored-by: haszi <haszika80@gmail.com>
This adds support for 'known' attributes on method and function parameters.
'Known' in this context means an attribute that has been declared in the documentation with an ID in the `class.attribute_name` format (all current predefined attributes are supported).
Current limitations are:
- No support for namespaced attributes
- No support for attributes on a return type
Co-authored-by: haszi <haszika80@gmail.com>
* Enable nested roles
Refactor role to be an array instead of a string to allow nesting of roles.
Use the indent method to format constant list tables.
Add tests for regular, table formatted and nested role containing variablelists.
* Make role property private
Add methods to push, pop and get role, and use these for all role accesses.
Make underlying $role array private.
Add comment on $role array being a LIFO stack.
---------
Co-authored-by: haszi <haszika80@gmail.com>
* Fix doc-en GH_3197
Fix void return type appended on void parameter list and add test for this fix.
Fix tests with incorrect expected output.
* Replace hardcoded html file extension for void type with the appropriate method call
---------
Co-authored-by: haszi <haszika80@gmail.com>
Declare all previously dynamic properties as far up the class hierarchy as needed and remove all declarations further down the inheritance tree.
Remove one nonexistent variable.
Co-authored-by: haszi <haszika80@gmail.com>
* Add table formatting for constant lists
* Add description and constants autogen text to .ini files
* Add language specific header to constant list table
---------
Co-authored-by: haszi <haszika80@gmail.com>
- Adds cchunk variable for tracking if a classsynopsis is actually an interface
- Render extends instead of implements for interfaces
- Render interface instead of class