changeset c93004ca174a in trytond:default
details: https://hg.tryton.org/trytond?cmd=changeset;node=c93004ca174a
description:
Add width and height attributes on calendar view
issue9148
review250931003
diffstat:
CHANGELOG | 1 +
doc/topics/views/index.rst | 4 ++++
trytond/ir/ui/calendar.rnc | 4 ++++
trytond/ir/ui/calendar.rng | 16 ++++++++++++++++
4 files changed, 25 insertions(+), 0 deletions(-)
diffs (62 lines):
diff -r 3475324686b2 -r c93004ca174a CHANGELOG
--- a/CHANGELOG Wed Apr 01 23:56:17 2020 +0200
+++ b/CHANGELOG Wed Apr 01 23:58:49 2020 +0200
@@ -1,3 +1,4 @@
+* Add width and height attributes on calendar view
* Add default database name configuration
* Add retry option to report convert
* Add depends fields on view_attributes
diff -r 3475324686b2 -r c93004ca174a doc/topics/views/index.rst
--- a/doc/topics/views/index.rst Wed Apr 01 23:56:17 2020 +0200
+++ b/doc/topics/views/index.rst Wed Apr 01 23:58:49 2020 +0200
@@ -843,6 +843,10 @@
* ``background_color``: An optional field name that contains the background
color for the event. The default value is `lightblue`.
+ * ``width``: The minimum width the calendar should request, use -1 to
unset.
+
+ * ``height``: The minimum height the calendar should request, use -1 to
unset.
+
field
^^^^^
diff -r 3475324686b2 -r c93004ca174a trytond/ir/ui/calendar.rnc
--- a/trytond/ir/ui/calendar.rnc Wed Apr 01 23:56:17 2020 +0200
+++ b/trytond/ir/ui/calendar.rnc Wed Apr 01 23:58:49 2020 +0200
@@ -14,6 +14,10 @@
[ a:defaultValue = "black" ] attribute color { text }?
attlist.calendar &=
[ a:defaultValue = "lightblue" ] attribute background_color { text }?
+attlist.calendar &=
+ attribute width { text }?
+attlist.calendar &=
+ attribute height { text }?
field = element field { attlist.field, empty }
attlist.field &= attribute name { text }
data = element data { attlist.data, xpath* }
diff -r 3475324686b2 -r c93004ca174a trytond/ir/ui/calendar.rng
--- a/trytond/ir/ui/calendar.rng Wed Apr 01 23:56:17 2020 +0200
+++ b/trytond/ir/ui/calendar.rng Wed Apr 01 23:58:49 2020 +0200
@@ -63,6 +63,22 @@
</attribute>
</optional>
</define>
+ <define name="attlist.calendar" combine="interleave">
+ <optional>
+ <attribute>
+ <name ns="">width</name>
+ <text/>
+ </attribute>
+ </optional>
+ </define>
+ <define name="attlist.calendar" combine="interleave">
+ <optional>
+ <attribute>
+ <name ns="">height</name>
+ <text/>
+ </attribute>
+ </optional>
+ </define>
<define name="field">
<element>
<name ns="">field</name>