mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-15 06:05:58 -06:00
Painter: Edge case stroker issue fixed
This commit is contained in:
parent
14f2def2bb
commit
8a3540d497
8 changed files with 56 additions and 64 deletions
|
|
@ -33,6 +33,7 @@ private:
|
|||
double fid;
|
||||
double tw;
|
||||
|
||||
Pointf first;
|
||||
Pointf p0, v0, o0, a0, b0;
|
||||
Pointf p1, v1, o1, a1, b1;
|
||||
Pointf p2;
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
#include "Painter.h"
|
||||
|
||||
#define LLOG(x) // DLOG(x)
|
||||
#define LLOG(x) // DLOG(x)
|
||||
|
||||
namespace Upp {
|
||||
|
||||
|
|
@ -17,6 +17,7 @@ void Stroker::Init(double width, double miterlimit, double tolerance, int _linec
|
|||
qmiter *= qmiter;
|
||||
fid = acos(1 - tolerance / w2);
|
||||
p0 = p1 = p2 = Null;
|
||||
first = Null;
|
||||
lines = 0;
|
||||
}
|
||||
|
||||
|
|
@ -24,7 +25,7 @@ void Stroker::Move(const Pointf& p)
|
|||
{
|
||||
LLOG("Stroker::Move " << p);
|
||||
Finish();
|
||||
p1 = p;
|
||||
first = p1 = p;
|
||||
p0 = p2 = Null;
|
||||
}
|
||||
|
||||
|
|
@ -56,7 +57,11 @@ void Stroker::Line(const Pointf& p3)
|
|||
Move(p3);
|
||||
return;
|
||||
}
|
||||
if(IsNull(p2)) {
|
||||
|
||||
Pointf v2 = p3 - p2;
|
||||
double l = Length(v2);
|
||||
|
||||
if(IsNull(p2) || l < 1e-15) {
|
||||
Pointf v = p3 - p1;
|
||||
double l = Length(v);
|
||||
if(l < 1e-8) // lower precision to accomodate Arc precision issue
|
||||
|
|
@ -76,10 +81,6 @@ void Stroker::Line(const Pointf& p3)
|
|||
return;
|
||||
}
|
||||
|
||||
Pointf v2 = p3 - p2;
|
||||
double l = Length(v2);
|
||||
if(l < 1e-15)
|
||||
return;
|
||||
Pointf o2 = Orthogonal(v2) * w2 / l;
|
||||
Pointf a2 = p2 + o2;
|
||||
Pointf b2 = p2 - o2;
|
||||
|
|
@ -155,7 +156,7 @@ void Stroker::Finish()
|
|||
{
|
||||
if(IsNull(p1) || IsNull(p2) || IsNull(p0))
|
||||
return;
|
||||
LLOG("-- Finish " << p1 << " " << p2 << ", lines " << lines);
|
||||
LLOG("-- Finish " << p1 << " to " << p2 << ", lines " << lines);
|
||||
if(lines == 1 && !IsNull(preclip) && PreClipped(p1, p2)) { // this is mostly intended to preclip dasher segments
|
||||
LLOG("FINISH PRECLIPPED " << p1 << " - " << p2);
|
||||
lines = 0;
|
||||
|
|
@ -168,10 +169,12 @@ void Stroker::Finish()
|
|||
PutLine(a1 + v1);
|
||||
PutMove(b1 + v1);
|
||||
PutLine(b1);
|
||||
Cap(p0, v0, o0, b0, a0);
|
||||
Cap(p2, -v1, -o1, a1 + v1, b1 + v1);
|
||||
if(p2 != first) {
|
||||
Cap(p0, v0, o0, b0, a0);
|
||||
Cap(p2, -v1, -o1, a1 + v1, b1 + v1);
|
||||
}
|
||||
}
|
||||
p0 = p1 = p2 = Null;
|
||||
first = p0 = p1 = p2 = Null;
|
||||
lines = 0;
|
||||
LLOG("* done");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -12,7 +12,7 @@ matching bracket.]&]
|
|||
/ next word.]&]
|
||||
[s0; [*@(0.0.255)2 Ctrl`+C][2 Copy selection if any, ][/2 current line][2
|
||||
otherwise.]&]
|
||||
[s0; [*@(0.0.255)2 Ctrl`+Y ][2 (or ][*@(0.0.255)2 Ctrl`+L][2 ) Cut current
|
||||
[s0; [*@(0.0.255)2 Ctrl`+Y ][2 or ][*@(0.0.255)2 Ctrl`+L][2 Cut current
|
||||
line.]&]
|
||||
[s0; [*@(0.0.255)2 Tab][2 / ][*@(0.0.255)2 Shift`+Tab][2 When selection
|
||||
is defined, indent selection right / left.]&]
|
||||
|
|
@ -27,6 +27,8 @@ to end of the file.]&]
|
|||
end.]&]
|
||||
[s0; [*@(0.0.255)2 Ctrl`+Backspace][2 Delete identifier from cursor
|
||||
to beginning.]&]
|
||||
[s0; [*@(0.0.255)2 Alt`+Shift`+Up/Down/Left/Right][2 Multiline cursor
|
||||
/ rectangular selection.]&]
|
||||
[s0; [2
|
||||
@@image:120&120/25
|
||||
(BGAAYAAAAAAAAAAAAHic7dpZbgIxEARQjpWL5P5HIV9IaAL2uLeqXlqaT3D5lQ1SwuPBPz+/z6fkQefOOFLr6UQ+3ubTxf9BmXfvAu3ctQe0a9cerDxOp3sPkdYRnaA9T4bJ3LILtOtu2M2/TYUeMrpfJ2sH2d2vk6mDKPvoz7YMHXg6SL4fUTmq2FubR+Zismd1986ZzR7l7pk5gz3a2zs/qz3a17KHyA462TN20M3eam9jn7sDbTa0XVQHu9cjzj7qLKLWtvZnstdM1g6kOVjcvXJJ18hk7zVZOqhoH5lT41/17Ftnlb5/hbPv/R6oO4A8+9ZmrP6rDljPvlenbHeA9eyz9erhL1mD+ewzvP/qNSxnv2u/Wv8sNuh93PFnzF3d/70DpE2EPes5Qn/2rNbL5i9Zg83f8xn/8f/kj85cxd56ner2XnuxWquCf7T9+N+zH/+a9uOPte/uj7bv7M9g39Wfxb6jP5N9N382+/HH5+ziz2hv7ca4P+ZskkxZ//7MmO00U9a//6+GMVcX/2y5GP7/XsVfYsXw+5Pq/qvXMPz+qqs/0+8Ps/tLjJh+f5v9kfhc/bPdAZbH4uyPP7f/dGBr8s1/7oC//8o+yx1gzrDLsfPPcAeYM6xy3LHPcAdY199luOvP3gHj2pb2Gv8IB7Z1PfyZO2Ba08t+54/uIPLR7lPqr70DFTrQ7lFj370DBvudf9UOLPZk5d+tAzZ7yw6Ye7DK72Fv3QFTD5aZPe09OkD2YJ0zwv5uB8w9eOSKtPfswKsLzxwI+5MONPuX9hG1HtL+NVEmUZPJ/jWRZ9NrTvaA9v400Z8RVnOaG+28m8jvxyjzDO7vI9mfdxeaTGhP6Wj2rOnEal20n9VYeUQ9aC+vQbt2db8O2rmr+6cZc54Zc76pbP0HrMjArg==)
|
||||
|
|
|
|||
|
|
@ -1,9 +1,9 @@
|
|||
TITLE("Ctrl+Tab - cycle through files")
|
||||
COMPRESSED
|
||||
120,156,141,85,11,143,154,88,20,254,43,36,221,109,218,50,219,11,151,199,133,105,154,20,69,197,25,148,235,91,153,152,45,143,139,128,60,148,151,202,102,255,251,162,182,59,221,109,157,150,132,112,146,115,206,247,125,231,21,158,52,254,131,45,113,31,222,241,212,111,191,177,119,204,43,6,73,34,207,242,136,231,5,200,33,129,231,33,195,243,44,219,216,172,128,68,132,238,139,160,136,200,250,233,146,68,179,44,106,242,224,29,124,197,10,188,216,134,109,245,28,219,82,90,140,2,197,182,192,241,170,216,101,217,142,202,114,247,121,105,127,73,109,50,152,51,211,79,158,123,149,120,86,25,21,235,167,191,254,252,251,247,206,240,143,217,132,122,202,153,15,212,211,187,79,111,152,247,204,123,40,8,111,33,213,46,178,232,51,61,181,236,245,19,164,168,246,201,137,8,229,5,17,201,223,175,95,175,127,16,223,201,29,234,28,58,241,211,3,240,3,151,80,118,90,20,105,76,237,172,132,220,200,81,162,226,51,173,19,175,184,112,128,38,255,123,247,56,216,248,87,127,47,165,108,203,
|
||||
217,2,47,205,14,86,230,222,192,188,234,254,252,244,99,200,47,222,245,197,59,36,199,162,9,217,101,164,10,210,50,167,98,171,112,252,32,217,80,118,214,240,144,226,69,134,219,178,175,254,103,221,248,43,62,160,146,51,227,33,253,137,248,246,181,229,233,238,68,229,36,34,78,17,164,9,21,120,148,149,156,238,26,50,0,41,167,204,50,146,20,84,20,36,228,18,156,22,62,201,14,65,126,171,211,87,224,213,101,66,111,210,236,199,146,245,179,247,45,213,46,139,255,16,220,128,252,186,26,223,213,63,241,3,175,120,94,157,133,79,146,111,235,200,41,151,120,13,172,123,71,5,137,123,38,121,118,102,231,166,53,136,81,211,220,27,180,95,208,175,138,103,187,23,37,92,131,212,244,144,92,194,6,105,69,46,21,129,103,198,114,7,220,198,255,98,219,110,177,252,15,126,226,100,105,20,125,69,124,9,16,91,27,242,5,244,230,48,180,52,38,215,121,52,123,95,52,171,79,54,65,66,165,30,213,76,250,114,136,47,74,62,51,252,43,236,38,71,39,113,191,165,32,137,251,203,
|
||||
4,106,211,193,226,186,123,87,147,10,206,179,12,188,128,100,148,151,53,119,223,172,80,222,16,95,113,95,196,106,53,215,150,239,44,231,23,225,46,157,72,154,59,125,6,133,212,167,79,65,220,212,124,207,66,230,117,243,2,40,188,105,245,20,101,165,124,243,104,129,131,220,157,105,111,250,199,142,50,30,133,187,133,46,96,65,235,207,229,190,165,232,176,212,201,126,25,237,173,41,167,10,209,136,157,28,74,220,194,53,13,106,209,219,142,136,103,24,93,61,19,103,35,154,43,237,233,209,147,91,241,210,171,148,146,115,138,17,97,44,217,33,153,122,52,118,92,142,183,238,106,156,88,138,60,229,237,7,78,239,235,133,81,148,112,0,193,116,53,35,131,108,231,61,192,92,131,46,172,182,98,172,62,226,42,173,209,106,160,45,55,226,68,231,189,217,52,222,195,110,105,143,105,51,200,99,151,149,37,209,172,199,40,66,187,173,176,169,57,11,214,57,216,55,95,22,61,106,39,133,23,225,116,8,153,1,71,172,88,14,19,148,171,246,212,98,150,243,145,86,202,78,88,135,104,175,
|
||||
63,234,139,162,50,147,188,112,7,236,70,220,26,243,208,169,150,15,15,172,228,111,81,61,55,141,189,159,106,66,52,229,89,192,162,110,145,68,182,0,124,27,87,96,44,166,6,175,72,180,108,198,25,22,51,53,10,113,21,145,196,214,136,34,147,83,45,147,204,215,217,88,165,201,161,174,48,216,15,39,199,164,130,37,88,84,82,62,44,125,153,195,221,164,238,114,46,64,140,186,235,192,14,38,185,48,74,0,204,134,182,46,4,178,185,145,56,79,58,38,64,242,192,54,148,4,231,232,10,98,66,50,184,76,202,227,98,95,182,61,52,149,233,33,93,107,128,182,228,210,192,5,1,101,136,236,10,13,228,13,39,47,188,163,45,134,88,24,202,67,78,130,52,208,52,129,174,131,26,250,21,114,44,30,211,102,190,221,30,77,0,208,32,54,24,102,38,91,0,136,116,111,48,119,150,0,158,132,30,70,96,153,207,189,85,190,60,208,2,222,131,125,181,28,52,131,222,239,115,192,208,18,206,65,161,135,15,62,237,9,149,188,245,124,7,216,216,85,76,91,227,203,19,198,200,3,
|
||||
110,175,149,73,57,11,80,218,6,64,74,233,211,145,221,212,153,170,231,30,198,142,66,86,3,241,120,226,116,173,177,221,21,43,203,81,105,84,152,219,104,33,220,217,176,87,73,253,22,50,89,236,157,76,3,182,44,70,42,104,129,7,101,31,235,205,148,241,62,107,250,213,157,102,35,20,117,67,174,177,91,85,233,122,242,204,208,177,185,21,92,186,80,106,19,157,14,226,138,32,245,17,193,110,197,141,186,83,85,176,76,76,24,217,216,170,112,245,192,212,135,74,40,91,210,65,38,198,228,177,192,94,126,120,204,245,250,120,232,211,194,192,24,226,114,41,251,61,86,43,116,122,56,239,196,51,19,63,128,112,49,54,229,97,54,173,154,165,173,120,134,49,165,241,60,49,172,30,13,165,88,10,171,227,41,172,85,3,85,125,57,246,220,35,177,166,61,31,139,139,16,102,70,210,177,34,200,36,242,124,69,102,35,217,106,211,213,200,46,160,107,75,6,204,226,140,22,29,211,17,120,211,65,226,206,198,140,150,13,66,37,219,124,252,248,246,114,230,205,95,156,138,211,140,80,69,
|
||||
176,203,215,235,245,63,255,103,198,100,
|
||||
120,156,141,86,137,142,218,72,16,253,21,75,217,141,146,120,54,109,183,239,137,34,197,96,192,204,24,220,48,156,30,161,141,143,54,182,241,1,237,3,240,106,255,125,13,204,236,100,55,97,18,75,136,150,170,234,189,234,87,175,44,63,234,252,39,71,230,62,125,224,169,223,126,99,111,152,55,140,36,139,60,203,75,60,47,64,78,18,120,30,50,60,207,178,205,153,21,36,81,146,110,139,176,136,241,234,241,92,68,179,172,212,212,193,27,248,134,21,120,177,13,219,218,41,183,165,182,24,21,138,109,129,227,53,177,203,178,29,141,229,110,243,210,121,42,109,42,152,19,211,79,158,91,13,251,118,25,23,171,199,191,254,252,251,247,206,240,143,233,3,245,152,51,159,168,199,15,95,222,49,31,153,143,80,16,222,67,170,93,144,248,43,61,177,157,213,35,164,168,246,209,141,49,229,135,49,206,63,174,222,174,126,144,223,201,93,234,148,250,16,100,123,16,132,30,166,156,172,40,178,132,218,218,41,190,82,163,198,197,87,218,192,126,113,230,0,77,253,247,225,113,184,14,46,241,94,
|
||||
70,57,182,187,1,126,70,246,54,241,174,96,94,250,254,250,248,99,200,167,232,234,28,29,226,67,209,164,108,9,174,194,172,204,169,196,46,220,32,76,215,148,67,26,30,92,188,202,112,189,237,75,252,165,111,244,140,15,168,244,196,184,207,126,210,124,251,34,121,182,61,82,57,142,177,91,132,89,74,133,62,101,167,199,155,134,12,64,202,45,9,193,105,65,197,97,138,207,201,89,17,96,178,15,243,107,74,95,128,151,231,9,101,228,199,29,27,23,218,178,248,15,252,21,192,103,99,124,119,251,135,32,244,139,23,227,204,3,156,126,123,139,156,242,176,223,192,122,55,84,152,122,39,146,151,32,57,73,214,32,198,141,180,87,104,159,208,47,13,79,183,175,182,112,73,210,178,125,122,78,27,100,21,62,223,8,188,48,150,91,224,53,241,87,69,187,198,242,63,248,7,151,100,113,252,140,248,26,32,178,215,248,9,244,221,181,89,232,89,114,30,236,251,147,235,139,198,248,120,29,166,84,230,83,205,156,207,107,248,106,203,39,134,127,27,187,202,209,73,189,111,41,112,234,253,50,
|
||||
129,214,40,88,92,156,119,57,82,225,105,150,161,31,98,66,249,164,217,250,198,66,121,67,124,193,125,21,171,213,236,90,190,181,221,95,132,59,43,145,54,91,250,218,59,229,201,1,211,45,56,201,0,78,187,10,94,22,114,208,188,253,194,147,19,158,97,1,69,26,67,216,233,186,140,109,242,98,200,23,6,72,125,249,18,38,141,170,183,44,100,222,54,63,0,133,119,173,158,170,46,213,111,30,61,116,37,111,107,57,235,254,161,163,142,71,209,118,110,8,72,208,251,51,165,111,171,6,44,13,188,91,196,59,123,194,105,66,60,98,31,246,37,106,161,154,6,181,232,111,70,216,55,205,174,65,196,233,136,230,74,103,114,240,149,86,178,240,43,181,228,220,98,132,25,91,113,49,209,14,230,150,203,209,198,91,142,83,91,85,38,188,115,199,25,125,163,48,139,18,14,32,152,44,167,120,64,182,254,29,204,117,232,193,106,35,38,218,61,170,178,90,90,14,244,197,90,124,48,120,127,58,73,118,176,91,58,99,218,10,243,196,99,21,89,180,234,177,20,75,219,141,176,174,57,27,
|
||||
214,57,216,53,255,172,116,175,31,85,94,132,147,33,100,6,28,182,19,37,74,165,92,115,38,54,179,152,141,244,82,113,163,58,146,118,198,189,49,47,42,43,205,11,111,192,174,197,141,57,139,220,106,113,119,199,202,193,70,170,103,150,185,11,50,93,136,39,60,11,88,169,91,164,177,35,128,192,65,21,24,139,153,201,171,50,173,88,9,65,34,209,226,8,85,49,78,29,29,171,10,62,214,10,38,129,193,38,26,141,247,117,133,192,110,248,112,72,43,88,130,121,37,231,195,50,80,56,212,77,235,46,231,1,137,209,182,29,216,65,56,23,70,41,128,100,232,24,66,168,88,107,153,243,229,67,10,100,31,108,34,89,112,15,158,32,166,152,192,69,90,30,230,187,178,237,75,19,133,30,210,181,14,104,91,41,77,84,96,80,70,146,83,73,3,101,205,41,115,255,224,136,17,18,134,202,144,147,33,13,116,93,160,235,176,134,65,37,185,54,143,104,43,223,108,14,22,0,210,32,49,25,102,170,216,0,136,116,111,48,115,23,0,30,133,30,146,192,34,159,249,203,124,177,167,5,
|
||||
180,3,187,106,49,104,6,189,219,229,128,161,101,148,131,194,136,238,2,218,23,42,101,227,7,46,112,144,167,90,142,206,151,71,132,36,31,120,189,22,145,115,22,72,89,27,0,57,163,143,7,118,93,19,205,200,125,132,92,21,47,7,226,225,200,25,122,115,246,150,172,162,196,165,89,33,110,173,71,112,235,192,94,37,247,91,146,197,34,255,104,153,176,101,51,114,65,11,60,40,251,200,104,166,140,118,164,209,171,59,33,35,41,238,70,92,115,110,85,165,231,43,83,211,64,214,70,240,232,66,173,45,233,184,23,151,88,210,238,37,216,173,184,81,119,162,9,182,133,48,163,152,27,13,46,239,152,122,95,9,101,75,222,43,216,124,184,47,144,159,239,239,115,163,62,236,251,180,48,48,135,168,92,40,65,143,213,11,131,30,206,58,201,212,66,119,32,154,143,45,101,72,38,85,99,218,138,103,24,75,30,207,82,211,238,209,80,78,228,168,58,28,163,90,51,165,170,175,36,190,119,192,246,164,23,32,113,30,65,98,166,29,59,134,76,170,204,150,120,58,82,236,54,93,141,156,
|
||||
2,122,142,108,66,146,16,90,116,45,87,224,45,87,18,183,14,98,116,50,136,84,178,254,252,249,253,121,201,155,175,4,42,201,8,166,138,112,155,175,86,171,127,0,37,78,230,106,
|
||||
|
||||
|
|
|
|||
9
upptst/PainterCircle/PainterCircle.upp
Normal file
9
upptst/PainterCircle/PainterCircle.upp
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
uses
|
||||
CtrlLib;
|
||||
|
||||
file
|
||||
main.cpp;
|
||||
|
||||
mainconfig
|
||||
"" = "GUI";
|
||||
|
||||
20
upptst/PainterCircle/main.cpp
Normal file
20
upptst/PainterCircle/main.cpp
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
#include <CtrlLib/CtrlLib.h>
|
||||
#include <Painter/Painter.h>
|
||||
|
||||
using namespace Upp;
|
||||
|
||||
struct MyApp : public TopWindow {
|
||||
void Paint(Draw& draw) override {
|
||||
DrawPainter w(draw, GetSize());
|
||||
w.Clear(White());
|
||||
// w.Circle(1400 + 760, 750, 600).Stroke(150, Blue());
|
||||
w.Scale(150);
|
||||
DLOG("============================ HERE");
|
||||
w.Circle(5, 5, 4).Stroke(1, Blue());
|
||||
}
|
||||
};
|
||||
|
||||
GUI_APP_MAIN
|
||||
{
|
||||
MyApp().Run();
|
||||
}
|
||||
|
|
@ -2,20 +2,6 @@
|
|||
|
||||
using namespace Upp;
|
||||
|
||||
void RoundedRectangle(Painter& p, double x, double y, double cx, double cy, double rx, double ry)
|
||||
{
|
||||
ASSERT(rx >= 0 && ry >= 0);
|
||||
if (cx < 0) { x += cx; cx = -cx;}
|
||||
if (cy < 0) { y += cy; cy = -cy;}
|
||||
p.Move(x + rx, y).Arc(x + rx, y + ry, rx, ry, -M_PI / 2, -M_PI / 2);
|
||||
return;
|
||||
p.Line(x, y + cy - ry)//.Arc(x + rx, y + cy - ry, rx, ry, M_PI, -M_PI / 2)
|
||||
// .Line(x + cx - rx, y + cy)//.Arc(x + cx - rx, y + cy - ry, rx, ry, M_PI / 2, -M_PI / 2)
|
||||
.Line(x + cx, y + ry)//.Arc(x + cx - rx, y + ry, rx, ry, 0, -M_PI / 2)
|
||||
.Line(x + rx, y);
|
||||
|
||||
}
|
||||
|
||||
struct MyApp : public TopWindow {
|
||||
void Paint(Draw& w) override {
|
||||
DrawPainter p(w, GetSize());
|
||||
|
|
@ -23,37 +9,10 @@ struct MyApp : public TopWindow {
|
|||
p.Scale(22);
|
||||
p.Translate(5, 5);
|
||||
DLOG("===============");
|
||||
// p.LineJoin(LINEJOIN_ROUND);
|
||||
#if 1
|
||||
p.RoundedRectangle(-2, -2, 100, 100, 5, 5);
|
||||
// RoundedRectangle(p, -2, -2, 100, 100, 5, 5);
|
||||
p.Stroke(5, Blue());
|
||||
#endif
|
||||
#if 1
|
||||
DLOG("---------------");
|
||||
p.Translate(20, 0);
|
||||
p
|
||||
.Move(3, -2)
|
||||
.Line(3, -2)
|
||||
.Line(2.4887790452444, -1.97418556365037)
|
||||
.Line(1.99232560327025, -1.89841777096139)
|
||||
.Line(1.51315294861739, -1.77520989647291)
|
||||
.Line(1.05377435582567, -1.60707521472478)
|
||||
.Line(0.616703099434949, -1.39652700025684)
|
||||
.Line(0.204452453985074, -1.14607852760896)
|
||||
.Line(-0.180464305984105, -0.858243071320971)
|
||||
.Line(-0.535533905932737, -0.535533905932738)
|
||||
.Line(-0.858243071320971, -0.180464305984106)
|
||||
.Line(-1.14607852760896, 0.204452453985073)
|
||||
.Line(-1.39652700025684, 0.616703099434948)
|
||||
.Line(-1.60707521472478, 1.05377435582567)
|
||||
.Line(-1.77520989647291, 1.51315294861739)
|
||||
.Line(-1.89841777096139, 1.99232560327025)
|
||||
.Line(-1.97418556365037, 2.4887790452444)
|
||||
.Line(-2, 3)
|
||||
.Line(-2, 3)
|
||||
;
|
||||
p.Stroke(5, Blue());
|
||||
#endif
|
||||
}
|
||||
};
|
||||
|
|
|
|||
|
|
@ -11,13 +11,11 @@ struct MyApp : public TopWindow {
|
|||
p.Clear(White());
|
||||
p.Scale(22);
|
||||
DLOG("-----------------------------");
|
||||
p.Move(10, 10);
|
||||
p.Arc(10, 10, 0.1, M_PI, M_PI);
|
||||
// p.RoundedRectangle(2, 2, 100, 100, 0.1)
|
||||
// p.Move(10, 10);
|
||||
// p.Arc(10, 10, 0.1, M_PI, M_PI);
|
||||
p.RoundedRectangle(2, 2, 100, 100, 0.1);
|
||||
p.Stroke(5, Blue());
|
||||
// p.Stroke(0.1, Blue());
|
||||
|
||||
p.Circle(20, 20, 10).Stroke(1, Blue());
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue