mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-05-15 14:16:07 -06:00
13 lines
352 B
C++
13 lines
352 B
C++
#include "LionBenchmark.h"
|
|
|
|
void ClippingExample(Painter& sw)
|
|
{
|
|
Font fnt = Roman(150).Bold();
|
|
String txt = "CLIPPED!";
|
|
Size tsz = GetTextSize(txt, fnt);
|
|
sw.Begin();
|
|
sw.Ellipse(tsz.cx / 2, tsz.cy / 2, tsz.cx / 2, tsz.cy / 4).Clip();
|
|
sw.Text(0, 0, txt, fnt).Fill(Green());
|
|
sw.End();
|
|
sw.Text(0, 0, txt, fnt).Stroke(0.5, Black());
|
|
}
|