[Cuis-dev] Circular toolbar

Hilaire Fernandes hilaire at drgeo.eu
Wed May 20 07:23:41 PDT 2020


The sub-optimal rendering of the complete ring is a bit slow but it is 
expected.

With imageForm 0:00:00:01.409

Without imageForm 0:00:00:01.266


| c p center draw |
"Feature require: 'VectorGraphics'."
c _ VectorCanvas onForm: Display.
center _ 1300 at 400.
draw _ [: angle |
c  strokeWidth: 3 color: Color blue darker fillColor: (Color blue lighter alpha:0.6) do: [ :e |
	p _ (Point r: 140 degrees: 80 + angle) * (1@ -1) + center.
	e abs_MoveToX: p x y: p y.
	p _ (Point r: 200 degrees: 80 + angle ) * (1@ -1) + center.
	e abs_LineToX: p x y: p y.
	p _ (Point r: 200 degrees: 100 + angle) * (1@ -1) + center.
	e abs_ArcToX: p x y: p y radiusX: 200 radiusY: 200 angleOfXAxis: 20 degreesToRadians largeFlag: false sweepFlag: false.
	p _ (Point r: 140 degrees: 100 + angle ) * (1@ -1) + center.
	e abs_LineToX: p x y: p y.
	p _ (Point r: 140 degrees: 80 + angle) * (1@ -1) + center.
	e abs_ArcToX: p x y: p y  radiusX: 140 radiusY: 140 angleOfXAxis: 20 degreesToRadians largeFlag: false sweepFlag: true].
Display forceToScreen.
p _ (Point r: 170 degrees: 90 + angle) * (1@ -1) + center - 24 asPoint.
DrGIcons line displayOn: Display at: p rule: Form blend].

[0 to: 20 * 17 by: 20 do: [:each | draw value: each]] durationToRun


-- 
GNU Dr. Geo
http://drgeo.eu

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20200520/81a46915/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Capture d??cran de 2020-05-20 16-15-22.jpg
Type: image/jpeg
Size: 49151 bytes
Desc: not available
URL: <http://lists.cuis.st/mailman/archives/cuis-dev/attachments/20200520/81a46915/attachment-0001.jpg>


More information about the Cuis-dev mailing list