Excellent scripts Milton!

Alexandre
-- 
_,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
Alexandre Bergel  http://www.bergel.eu
^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.



On Apr 7, 2017, at 6:10 AM, milton mamani <akevalion@gmail.com> wrote:

Hi Markus,

Is the month layout finally implemented in RTSVGPath in monthShapePath?
- could you please explain it?

How could one change month visualization and:

-   start weeks on Monday instead of Sunday.

---- RTCalendarBuilder uses RTDateLayout, and with this layout change the start of the weeks is not possible, we can improve that

- change color of day figure or background color based on criteria (e.g. weekend …)

---- You can use dateShape

I prepare this example, that I hope can resolve some of your questions.

| b |
b := RTCalendarBuilder new.
b dates: (Month current to: Month current next next).
b dateShape box size: 14.
b dateShape if: [:date | date dayOfWeek = 1 ]color: Color lightBlue .
b dateShape if: [:date | date dayOfWeek = 2 ]color: Color blue.
b monthShape shape: (b monthShapePath: 15.0).
b dateLayout gapSize: 1.
b monthLayout month.
b build.
(b view elements select: [:e | e model isKindOf: Month]) pushFront.
^ b view

<fa.png>

| b |
b := RTCalendarBuilder new.
b dates: (Month current to: Month current next next).
b dateShape shape: (RTPolygon star size: 20).
b dateShape if: [:date | date dayOfWeek = 1 ]color: Color lightBlue .
b dateShape if: [:date | date dayOfWeek = 2 ]color: Color blue.
b build.
^ b view

<foo.png>

Milton




Libre de virus. www.avast.com

2017-04-06 9:32 GMT-03:00 Markus Böhm <markus.boehm@gmail.com>:

May I ask: I’m trying to understand how to use RTCalendarBuilder in own, adapted calendar visualization, I read the chapter about builders in the book and started to look at:

exampleMonth

| b |

b := RTCalendarBuilder new.

b dates: (Month current to: Month current next).

b build.

^ b view

Is the month layout finally implemented in RTSVGPath in monthShapePath?

How could one change month visualization and:

-   start weeks on Monday instead of Sunday

-    change color of day figure or background color based on criteria (e.g. weekend …)

Only meant as example. Would I need to change SVGPaths or are there higher level methods?

BR Mike


_______________________________________________
Moose-dev mailing list
Moose-dev@list.inf.unibe.ch
https://www.list.inf.unibe.ch/listinfo/moose-dev


_______________________________________________
Moose-dev mailing list
Moose-dev@list.inf.unibe.ch
https://www.list.inf.unibe.ch/listinfo/moose-dev