summaryrefslogtreecommitdiff
path: root/drawinglayer
diff options
context:
space:
mode:
authorHossein <hossein.ir@gmail.com>2021-03-29 21:55:26 +0430
committerAdolfo Jayme Barrientos <fitojb@ubuntu.com>2021-04-07 17:47:16 +0200
commitea5641baeef73af60d025d185901a303844e2d85 (patch)
tree94b343b35e7b8805beb9a1745fe1de2f382574fb /drawinglayer
parent33da78c21f4243a3e469fb7df79ed1745df70078 (diff)
Updated README.md files to represent current code / use Markdown format
Previously, all of the README files have been renamed to README.md and now, the contents of these files were changed to use Markdown format. Other than format inconsistency, some README.md files lacked information about modules, or were out of date. By using LibreOffice / OpenOffice wiki and other documentation websites, these files were updated. Now every README.md file has a title, and some description. The top-level README.md file is changed to add links to the modules. The result of processing the Markdown format README.md files can be seen at: https://docs.libreoffice.org/ Change-Id: Ic3b0c3c064a2498d6a435253b041df010cd7797a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113424 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de> Reviewed-by: Adolfo Jayme Barrientos <fitojb@ubuntu.com>
Diffstat (limited to 'drawinglayer')
-rw-r--r--drawinglayer/README.md28
1 files changed, 15 insertions, 13 deletions
diff --git a/drawinglayer/README.md b/drawinglayer/README.md
index b530ba6fedac..38bdc2197c70 100644
--- a/drawinglayer/README.md
+++ b/drawinglayer/README.md
@@ -1,6 +1,8 @@
+# Drawing API
+
Drawing API that can specify what to draw via a kind of display list.
-Example of the DrawingLayer use is eg. in svx/source/xoutdev/xtabhtch.cxx:121.
+Example of the DrawingLayer use is eg. in `svx/source/xoutdev/xtabhtch.cxx:121`.
A stripped down version with extended comments:
// Create a hatch primitive (here a rectangle that will be filled with
@@ -39,7 +41,7 @@ A stripped down version with extended comments:
// it in the widget.
aRetval = aVirtualDevice.GetBitmap(Point(0, 0), aVirtualDevice.GetOutputSizePixel());
-== DrawingLayer glossary ==
+## DrawingLayer Glossary
Primitives - classes that represent what should be drawn. It holds the data
what to draw, but does not contain any kind of the rendering. Some of the
@@ -49,31 +51,31 @@ primitives.
Decomposition - a way how to break down the more complicated primitives into
the basic primitives, and represent them via them; this logically makes the
-plain Primitive2DSequence display list a hierarchy.
-Eg. PolygonMarkerPrimitive2D can be decomposed to 2 hairlines
-PolyPolygonHairlinePrimitive2D's, each with different color.
+plain `Primitive2DSequence` display list a hierarchy.
+Eg. `PolygonMarkerPrimitive2D` can be decomposed to 2 hairlines
+`PolyPolygonHairlinePrimitive2D`'s, each with different color.
Processor - a class that goes through the hierarchy of the Primitives, and
-renders it some way. Various processors, like VclPixelProcessor2D (renders to
-the screen), VclMetafileProcessor2D (renders to the VCL metafile, eg. for
+renders it some way. Various processors, like `VclPixelProcessor2D` (renders to
+the screen), `VclMetafileProcessor2D` (renders to the VCL metafile, eg. for
printing), etc.
-== How to Implement a new Primitive ("something new to draw") ==
+## How to Implement a New Primitive ("Something New to Draw")
-* Create an ancestor of BasePrimitive2D
+* Create an ancestor of `BasePrimitive2D`
(or of its ancestor if it fits the purpose better)
- * Assign it an ID [in drawinglayer_primitivetypes2d.hxx]
+ * Assign it an ID [in `drawinglayer_primitivetypes2d.hxx`]
* Implement its decomposition
- [virtual Primitive2DSequence create2DDecomposition(...)]
+ [`virtual Primitive2DSequence create2DDecomposition(...)`]
* Extend the (various) processor(s)
If you need more than relying on just the decomposition
-== Where is DrawingLayer used ==
+## Where is DrawingLayer Used
-* SdrObject(s) (rectangles, Circles, predefined shapes etc.)
+* `SdrObject`(s) (rectangles, Circles, predefined shapes etc.)
* Selections