/usr/share/doc/racket/draw/overview.html is in racket-doc 6.7-3.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 | <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"/><title>1 Overview</title><link rel="stylesheet" type="text/css" href="../scribble.css" title="default"/><link rel="stylesheet" type="text/css" href="../racket.css" title="default"/><link rel="stylesheet" type="text/css" href="../manual-style.css" title="default"/><link rel="stylesheet" type="text/css" href="../manual-racket.css" title="default"/><link rel="stylesheet" type="text/css" href="../doc-site.css" title="default"/><script type="text/javascript" src="../scribble-common.js"></script><script type="text/javascript" src="../manual-racket.js"></script><script type="text/javascript" src="../doc-site.js"></script><script type="text/javascript" src="../local-redirect/local-redirect.js"></script><script type="text/javascript" src="../local-redirect/local-user-redirect.js"></script><!--[if IE 6]><style type="text/css">.SIEHidden { overflow: hidden; }</style><![endif]--></head><body id="doc-racket-lang-org"><div class="tocset"><div class="tocview"><div class="tocviewlist tocviewlisttopspace"><div class="tocviewtitle"><table cellspacing="0" cellpadding="0"><tr><td style="width: 1em;"><a href="javascript:void(0);" title="Expand/Collapse" class="tocviewtoggle" onclick="TocviewToggle(this,"tocview_0");">▼</a></td><td></td><td><a href="index.html" class="tocviewlink" data-pltdoc="x">The Racket Drawing Toolkit</a></td></tr></table></div><div class="tocviewsublisttop" style="display: block;" id="tocview_0"><table cellspacing="0" cellpadding="0"><tr><td align="right">1 </td><td><a href="" class="tocviewselflink" data-pltdoc="x">Overview</a></td></tr><tr><td align="right">2 </td><td><a href="bitmap_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">bitmap%</span></span></a></td></tr><tr><td align="right">3 </td><td><a href="bitmap-dc_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">bitmap-<wbr></wbr>dc%</span></span></a></td></tr><tr><td align="right">4 </td><td><a href="brush_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">brush%</span></span></a></td></tr><tr><td align="right">5 </td><td><a href="brush-list_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">brush-<wbr></wbr>list%</span></span></a></td></tr><tr><td align="right">6 </td><td><a href="color_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">color%</span></span></a></td></tr><tr><td align="right">7 </td><td><a href="color-database___.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">color-<wbr></wbr>database<%></span></span></a></td></tr><tr><td align="right">8 </td><td><a href="dc___.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">dc<%></span></span></a></td></tr><tr><td align="right">9 </td><td><a href="dc-path_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">dc-<wbr></wbr>path%</span></span></a></td></tr><tr><td align="right">10 </td><td><a href="font_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">font%</span></span></a></td></tr><tr><td align="right">11 </td><td><a href="font-list_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">font-<wbr></wbr>list%</span></span></a></td></tr><tr><td align="right">12 </td><td><a href="font-name-directory___.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">font-<wbr></wbr>name-<wbr></wbr>directory<%></span></span></a></td></tr><tr><td align="right">13 </td><td><a href="gl-config_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">gl-<wbr></wbr>config%</span></span></a></td></tr><tr><td align="right">14 </td><td><a href="gl-context___.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">gl-<wbr></wbr>context<%></span></span></a></td></tr><tr><td align="right">15 </td><td><a href="linear-gradient_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">linear-<wbr></wbr>gradient%</span></span></a></td></tr><tr><td align="right">16 </td><td><a href="pdf-dc_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">pdf-<wbr></wbr>dc%</span></span></a></td></tr><tr><td align="right">17 </td><td><a href="pen_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">pen%</span></span></a></td></tr><tr><td align="right">18 </td><td><a href="pen-list_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">pen-<wbr></wbr>list%</span></span></a></td></tr><tr><td align="right">19 </td><td><a href="point_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">point%</span></span></a></td></tr><tr><td align="right">20 </td><td><a href="post-script-dc_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">post-<wbr></wbr>script-<wbr></wbr>dc%</span></span></a></td></tr><tr><td align="right">21 </td><td><a href="ps-setup_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">ps-<wbr></wbr>setup%</span></span></a></td></tr><tr><td align="right">22 </td><td><a href="radial-gradient_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">radial-<wbr></wbr>gradient%</span></span></a></td></tr><tr><td align="right">23 </td><td><a href="record-dc_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">record-<wbr></wbr>dc%</span></span></a></td></tr><tr><td align="right">24 </td><td><a href="region_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">region%</span></span></a></td></tr><tr><td align="right">25 </td><td><a href="svg-dc_.html" class="tocviewlink" data-pltdoc="x"><span class="RktSym"><span class="RktValLink">svg-<wbr></wbr>dc%</span></span></a></td></tr><tr><td align="right">26 </td><td><a href="Drawing_Functions.html" class="tocviewlink" data-pltdoc="x">Drawing Functions</a></td></tr><tr><td align="right">27 </td><td><a href="Drawing_Contracts.html" class="tocviewlink" data-pltdoc="x">Drawing Contracts</a></td></tr><tr><td align="right">28 </td><td><a href="Signature_and_Unit.html" class="tocviewlink" data-pltdoc="x">Signature and Unit</a></td></tr><tr><td align="right">29 </td><td><a href="unsafe.html" class="tocviewlink" data-pltdoc="x">Unsafe Libraries</a></td></tr><tr><td align="right">30 </td><td><a href="Drawing_Conveniences.html" class="tocviewlink" data-pltdoc="x">Drawing Conveniences</a></td></tr><tr><td align="right">31 </td><td><a href="libs.html" class="tocviewlink" data-pltdoc="x">Platform Dependencies</a></td></tr><tr><td align="right"></td><td><a href="doc-bibliography.html" class="tocviewlink" data-pltdoc="x">Bibliography</a></td></tr><tr><td align="right"></td><td><a href="doc-index.html" class="tocviewlink" data-pltdoc="x">Index</a></td></tr></table></div></div><div class="tocviewlist"><table cellspacing="0" cellpadding="0"><tr><td style="width: 1em;"><a href="javascript:void(0);" title="Expand/Collapse" class="tocviewtoggle" onclick="TocviewToggle(this,"tocview_1");">►</a></td><td>1 </td><td><a href="" class="tocviewselflink" data-pltdoc="x">Overview</a></td></tr></table><div class="tocviewsublistbottom" style="display: none;" id="tocview_1"><table cellspacing="0" cellpadding="0"><tr><td align="right">1.1 </td><td><a href="#%28part._.Lines_and_.Simple_.Shapes%29" class="tocviewlink" data-pltdoc="x">Lines and Simple Shapes</a></td></tr><tr><td align="right">1.2 </td><td><a href="#%28part._.Pen__.Brush__and_.Color_.Objects%29" class="tocviewlink" data-pltdoc="x">Pen, Brush, and Color Objects</a></td></tr><tr><td align="right">1.3 </td><td><a href="#%28part._.Transformations%29" class="tocviewlink" data-pltdoc="x">Transformations</a></td></tr><tr><td align="right">1.4 </td><td><a href="#%28part._.Drawing_.Paths%29" class="tocviewlink" data-pltdoc="x">Drawing Paths</a></td></tr><tr><td align="right">1.5 </td><td><a href="#%28part._.Text%29" class="tocviewlink" data-pltdoc="x">Text</a></td></tr><tr><td align="right">1.6 </td><td><a href="#%28part._.Alpha_.Channels_and_.Alpha_.Blending%29" class="tocviewlink" data-pltdoc="x">Alpha Channels and Alpha Blending</a></td></tr><tr><td align="right">1.7 </td><td><a href="#%28part._.Clipping%29" class="tocviewlink" data-pltdoc="x">Clipping</a></td></tr><tr><td align="right">1.8 </td><td><a href="#%28part._.Portability%29" class="tocviewlink" data-pltdoc="x">Portability and Bitmap Variants</a></td></tr></table></div></div></div><div class="tocsub"><div class="tocsubtitle">On this page:</div><table class="tocsublist" cellspacing="0"><tr><td><span class="tocsublinknumber">1.1<tt> </tt></span><a href="#%28part._.Lines_and_.Simple_.Shapes%29" class="tocsubseclink" data-pltdoc="x">Lines and Simple Shapes</a></td></tr><tr><td><span class="tocsublinknumber">1.2<tt> </tt></span><a href="#%28part._.Pen__.Brush__and_.Color_.Objects%29" class="tocsubseclink" data-pltdoc="x">Pen, Brush, and Color Objects</a></td></tr><tr><td><span class="tocsublinknumber">1.3<tt> </tt></span><a href="#%28part._.Transformations%29" class="tocsubseclink" data-pltdoc="x">Transformations</a></td></tr><tr><td><span class="tocsublinknumber">1.4<tt> </tt></span><a href="#%28part._.Drawing_.Paths%29" class="tocsubseclink" data-pltdoc="x">Drawing Paths</a></td></tr><tr><td><span class="tocsublinknumber">1.5<tt> </tt></span><a href="#%28part._.Text%29" class="tocsubseclink" data-pltdoc="x">Text</a></td></tr><tr><td><span class="tocsublinknumber">1.6<tt> </tt></span><a href="#%28part._.Alpha_.Channels_and_.Alpha_.Blending%29" class="tocsubseclink" data-pltdoc="x">Alpha Channels and Alpha Blending</a></td></tr><tr><td><span class="tocsublinknumber">1.7<tt> </tt></span><a href="#%28part._.Clipping%29" class="tocsubseclink" data-pltdoc="x">Clipping</a></td></tr><tr><td><span class="tocsublinknumber">1.8<tt> </tt></span><a href="#%28part._.Portability%29" class="tocsubseclink" data-pltdoc="x">Portability and Bitmap Variants</a></td></tr></table></div></div><div class="maincolumn"><div class="main"><div class="navsettop"><span class="navleft"><form class="searchform"><input class="searchbox" style="color: #888;" type="text" value="...search manuals..." title="Enter a search string to search the manuals" onkeypress="return DoSearchKey(event, this, "6.7", "../");" onfocus="this.style.color="black"; this.style.textAlign="left"; if (this.value == "...search manuals...") this.value="";" onblur="if (this.value.match(/^ *$/)) { this.style.color="#888"; this.style.textAlign="center"; this.value="...search manuals..."; }"/></form> <a href="../index.html" title="up to the documentation top" data-pltdoc="x" onclick="return GotoPLTRoot("6.7");">top</a></span><span class="navright"> <a href="index.html" title="backward to "The Racket Drawing Toolkit"" data-pltdoc="x">← prev</a> <a href="index.html" title="up to "The Racket Drawing Toolkit"" data-pltdoc="x">up</a> <a href="bitmap_.html" title="forward to "2 bitmap%"" data-pltdoc="x">next →</a></span> </div><h3 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""overview"">1<tt> </tt><a name="(part._overview)"></a>Overview</h3><p>The <a href="index.html" class="RktModLink" data-pltdoc="x"><span class="RktSym">racket/draw</span></a> library provides a drawing API that is
based on the PostScript drawing model. It supports line drawing, shape
filling, bitmap copying, alpha blending, and affine transformations
(i.e., scale, rotation, and translation).</p><blockquote class="refpara"><blockquote class="refcolumn"><blockquote class="refcontent"><p>See <a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=guide&rel=classes.html&version=6.7" class="Sq" data-pltdoc="x">Classes and Objects</a> for an introduction to classes and
interfaces in Racket.</p></blockquote></blockquote></blockquote><p>Drawing with <a href="index.html" class="RktModLink" data-pltdoc="x"><span class="RktSym">racket/draw</span></a> requires a <a name="(tech._drawing._context)"></a><span style="font-style: italic">drawing context</span>
(<a name="(tech._dc)"></a><span style="font-style: italic">DC</span>), which is an instance of the <span class="RktSym"><a href="dc___.html" class="RktValLink" data-pltdoc="x">dc<%></a></span>
interface. For example, the <span class="RktSym"><a href="post-script-dc_.html" class="RktValLink" data-pltdoc="x">post-script-dc%</a></span> class implements
a <span class="RktSym"><a href="dc___.html" class="RktValLink" data-pltdoc="x">dc<%></a></span> for drawing to a PostScript file, while <span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span>
draws to a bitmap. When using the <a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=index.html&version=6.7" class="RktModLink Sq" data-pltdoc="x"><span class="RktSym">racket/gui</span></a> library for GUIs,
the <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=canvas___.html%23%2528meth._%2528%2528%2528lib._mred%252Fmain..rkt%2529._canvas%7E3c%7E25%7E3e%2529._get-dc%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">get-dc</a></span> method of a
canvas returns a <span class="RktSym"><a href="dc___.html" class="RktValLink" data-pltdoc="x">dc<%></a></span> instance for drawing into the canvas
window.</p><blockquote class="refpara"><blockquote class="refcolumn"><blockquote class="refcontent"><p>See <a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=windowing-overview.html%23%2528part._canvas-drawing%2529&version=6.7" class="Sq" data-pltdoc="x">Drawing in Canvases</a> for an introduction to drawing
in a GUI window.</p></blockquote></blockquote></blockquote><h4 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""Lines_and_Simple_Shapes"">1.1<tt> </tt><a name="(part._.Lines_and_.Simple_.Shapes)"></a>Lines and Simple Shapes</h4><p>To draw into a bitmap, first create the bitmap with
<span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span>, and then create a <span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span> that draws
into the new bitmap:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">target</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">A 30x30 bitmap</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">bitmap</span><span class="hspace"> </span><span class="RktSym">target</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></blockquote><p>Then, use methods like <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-line%29%29" class="RktValLink" data-pltdoc="x">draw-line</a></span> on the <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a> to draw
into the bitmap. For example, the sequence</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span></td></tr><tr><td><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">10</span><span class="hspace"> </span><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">Top-left at (0, 10), 10 pixels down from top-left</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">10</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">30 pixels wide and 10 pixels high</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-line%29%29" class="RktValLink" data-pltdoc="x">draw-line</a></span></td></tr><tr><td><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">Start at (0, 0), the top-left corner</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">and draw to (30, 30), the bottom-right corner</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-line%29%29" class="RktValLink" data-pltdoc="x">draw-line</a></span></td></tr><tr><td><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">Start at (0, 30), the bottom-left corner</span></td></tr><tr><td><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">and draw to (30, 0), the top-right corner</span></td></tr></table></blockquote><p>draws an “X” on top of a smaller rectangle into the bitmap <span class="RktSym">target</span>. If
you save the bitmap to a file with <span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="stt"> </span><span class="RktSym">target</span><span class="stt"> </span><span class="RktSym"><a href="bitmap_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._bitmap~25%29._save-file%29%29" class="RktValLink" data-pltdoc="x">save-file</a></span><span class="stt"> </span><span class="RktVal">"box.png"</span><span class="stt"> </span><span class="RktVal">'</span><span class="RktVal">png</span><span class="RktPn">)</span>, the <span class="stt">"box.png"</span> contains the image</p><blockquote class="SCentered"><p><span class="RktRes"><img src="pict.png" alt="image" width="30" height="30"/></span></p></blockquote><p>in PNG format.</p><p>A line-drawing drawing operation like <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-line%29%29" class="RktValLink" data-pltdoc="x">draw-line</a></span> uses the
<a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>’s current <span style="font-style: italic">pen</span> to draw the line. A pen has a color,
line width, and style, where pen styles include <span class="RktVal">'</span><span class="RktVal">solid</span>,
<span class="RktVal">'</span><span class="RktVal">long-dash</span>, and <span class="RktVal">'</span><span class="RktVal">transparent</span>. Enclosed-shape
operations like <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span> use both the current pen and
the <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>’s current <a name="(tech._brush)"></a><span style="font-style: italic">brush</span>. A brush has a color and style,
where brush styles include <span class="RktVal">'</span><span class="RktVal">solid</span>, <span class="RktVal">'</span><span class="RktVal">cross-hatch</span>, and
<span class="RktVal">'</span><span class="RktVal">transparent</span>.</p><blockquote class="refpara"><blockquote class="refcolumn"><blockquote class="refcontent"><p>In DrRacket, instead of saving <span class="RktSym">target</span> to a file
viewing the image from the file, you can use <span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=require.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._require%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">require</a></span><span class="stt"> </span><span class="RktSym">racket/gui</span><span class="RktPn">)</span> and <span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528def._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._make-object%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-object</a></span><span class="stt"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=image-snip_.html&version=6.7" class="RktValLink Sq" data-pltdoc="x">image-snip%</a></span><span class="stt"> </span><span class="RktSym">target</span><span class="RktPn">)</span> to view the
bitmap in the DrRacket interactions window.</p></blockquote></blockquote></blockquote><p>For example, set the brush and pen before the drawing operations to
draw a thick, red “X” on a green rectangle with a thin, blue border:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktVal">"green"</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktVal">"blue"</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">10</span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">10</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktVal">"red"</span><span class="hspace"> </span><span class="RktVal">3</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-line%29%29" class="RktValLink" data-pltdoc="x">draw-line</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-line%29%29" class="RktValLink" data-pltdoc="x">draw-line</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_2.png" alt="image" width="30" height="30"/></span></p></blockquote><p>To draw a filled shape without an outline, set the pen to
<span class="RktVal">'</span><span class="RktVal">transparent</span> mode (with any color and line width). For
example,</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktVal">"white"</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">transparent</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktVal">"black"</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-ellipse%29%29" class="RktValLink" data-pltdoc="x">draw-ellipse</a></span><span class="hspace"> </span><span class="RktVal">5</span><span class="hspace"> </span><span class="RktVal">5</span><span class="hspace"> </span><span class="RktVal">20</span><span class="hspace"> </span><span class="RktVal">20</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_3.png" alt="image" width="30" height="30"/></span></p></blockquote><p>By default, a <span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span> draws solid pixels without smoothing
the boundaries of shapes. To enable smoothing, set the
smoothing mode to either <span class="RktVal">'</span><span class="RktVal">smoothed</span> or <span class="RktVal">'</span><span class="RktVal">aligned</span>:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-smoothing%29%29" class="RktValLink" data-pltdoc="x">set-smoothing</a></span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">aligned</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktVal">"black"</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-ellipse%29%29" class="RktValLink" data-pltdoc="x">draw-ellipse</a></span><span class="hspace"> </span><span class="RktVal">4</span><span class="hspace"> </span><span class="RktVal">4</span><span class="hspace"> </span><span class="RktVal">22</span><span class="hspace"> </span><span class="RktVal">22</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">a little bigger</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_4.png" alt="image" width="30" height="30"/></span></p></blockquote><p>The difference between <span class="RktVal">'</span><span class="RktVal">aligned</span> mode and <span class="RktVal">'</span><span class="RktVal">smoothed</span>
mode is related to the relatively coarse granularity of pixels in a
bitmap. Conceptually, drawing coordinates correspond to the lines
between pixels, and the pen is centered on the line. In
<span class="RktVal">'</span><span class="RktVal">smoothed</span> mode, drawing on a line causes the pen to draw at
half strength on either side of the line, which produces the following
result for a 1-pixel black pen:</p><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_5.png" alt="image" width="30" height="4"/></span></p></blockquote><p>but <span class="RktVal">'</span><span class="RktVal">aligned</span> mode shifts drawing coordinates to make the pen
fall on whole pixels, so a 1-pixel black pen draws a single line of
pixels:</p><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_6.png" alt="image" width="30" height="4"/></span></p></blockquote><h4 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""Pen__Brush__and_Color_Objects"">1.2<tt> </tt><a name="(part._.Pen__.Brush__and_.Color_.Objects)"></a>Pen, Brush, and Color Objects</h4><p>The <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span> and <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span> methods of a <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>
accept <span class="RktSym"><a href="pen_.html" class="RktValLink" data-pltdoc="x">pen%</a></span> and <span class="RktSym"><a href="brush_.html" class="RktValLink" data-pltdoc="x">brush%</a></span> objects, which group
together pen and brush settings.</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=require.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._require%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">require</a></span><span class="hspace"> </span><span class="RktSym">racket/math</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">no-pen</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="pen_.html" class="RktValLink" data-pltdoc="x">pen%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">style</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">transparent</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">no-brush</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="brush_.html" class="RktValLink" data-pltdoc="x">brush%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">style</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">transparent</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">blue-brush</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="brush_.html" class="RktValLink" data-pltdoc="x">brush%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">color</span><span class="hspace"> </span><span class="RktVal">"blue"</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">yellow-brush</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="brush_.html" class="RktValLink" data-pltdoc="x">brush%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">color</span><span class="hspace"> </span><span class="RktVal">"yellow"</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">red-pen</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="pen_.html" class="RktValLink" data-pltdoc="x">pen%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">color</span><span class="hspace"> </span><span class="RktVal">"red"</span><span class="RktPn">]</span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">width</span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">draw-face</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-smoothing%29%29" class="RktValLink" data-pltdoc="x">set-smoothing</a></span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">aligned</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktSym">no-pen</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktSym">blue-brush</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-ellipse%29%29" class="RktValLink" data-pltdoc="x">draw-ellipse</a></span><span class="hspace"> </span><span class="RktVal">25</span><span class="hspace"> </span><span class="RktVal">25</span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">100</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktSym">yellow-brush</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">50</span><span class="hspace"> </span><span class="RktVal">50</span><span class="hspace"> </span><span class="RktVal">10</span><span class="hspace"> </span><span class="RktVal">10</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">90</span><span class="hspace"> </span><span class="RktVal">50</span><span class="hspace"> </span><span class="RktVal">10</span><span class="hspace"> </span><span class="RktVal">10</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktSym">no-brush</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktSym">red-pen</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-arc%29%29" class="RktValLink" data-pltdoc="x">draw-arc</a></span><span class="hspace"> </span><span class="RktVal">37</span><span class="hspace"> </span><span class="RktVal">37</span><span class="hspace"> </span><span class="RktVal">75</span><span class="hspace"> </span><span class="RktVal">75</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">5/4</span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">7/4</span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">target</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span><span class="hspace"> </span><span class="RktVal">150</span><span class="hspace"> </span><span class="RktVal">150</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">bitmap</span><span class="hspace"> </span><span class="RktSym">target</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym">draw-face</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_7.png" alt="image" width="150" height="150"/></span></p></blockquote><p>The <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._get-pen%29%29" class="RktValLink" data-pltdoc="x">get-pen</a></span> and <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._get-brush%29%29" class="RktValLink" data-pltdoc="x">get-brush</a></span> methods return a
<a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>’s current pen and brush, so they can be restored after
changing them temporarily for drawing.</p><p>Besides grouping settings, a <span class="RktSym"><a href="pen_.html" class="RktValLink" data-pltdoc="x">pen%</a></span> or <span class="RktSym"><a href="brush_.html" class="RktValLink" data-pltdoc="x">brush%</a></span> object
includes extra settings that are not available by using
<span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span> or <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span> directly. For example, a pen or
brush can have a <a name="(tech._stipple)"></a><span style="font-style: italic">stipple</span>, which is a bitmap that is used
instead of a solid color when drawing. For example, if
<span class="stt">"water.png"</span> has the image</p><blockquote class="SCentered"><p><img src="water.png" alt="" width="48" height="45"/></p></blockquote><p>then it can be loaded with <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._read-bitmap%29%29" class="RktValLink" data-pltdoc="x">read-bitmap</a></span> and installed as the
stipple for <span class="RktSym">blue-brush</span>:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">blue-brush</span><span class="hspace"> </span><span class="RktSym"><a href="brush_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._brush~25%29._set-stipple%29%29" class="RktValLink" data-pltdoc="x">set-stipple</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._read-bitmap%29%29" class="RktValLink" data-pltdoc="x">read-bitmap</a></span><span class="hspace"> </span><span class="RktVal">"water.png"</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._erase%29%29" class="RktValLink" data-pltdoc="x">erase</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym">draw-face</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_8.png" alt="image" width="150" height="150"/></span></p></blockquote><p>Along similar lines, a <span class="RktSym"><a href="color_.html" class="RktValLink" data-pltdoc="x">color%</a></span> object lets you specify a color
through its red, green, and blue components instead of a built-in
color name. Due to the way that <span class="RktSym"><a href="color_.html" class="RktValLink" data-pltdoc="x">color%</a></span> initialization is
overloaded, use <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528def._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._make-object%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-object</a></span> instead of <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span> to
instantiate <span class="RktSym"><a href="color_.html" class="RktValLink" data-pltdoc="x">color%</a></span>, or use the <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-color%29%29" class="RktValLink" data-pltdoc="x">make-color</a></span> function:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">red-pen</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="pen_.html" class="RktValLink" data-pltdoc="x">pen%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">color</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-color%29%29" class="RktValLink" data-pltdoc="x">make-color</a></span><span class="hspace"> </span><span class="RktVal">200</span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">150</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">width</span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._erase%29%29" class="RktValLink" data-pltdoc="x">erase</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym">draw-face</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_9.png" alt="image" width="150" height="150"/></span></p></blockquote><h4 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""Transformations"">1.3<tt> </tt><a name="(part._.Transformations)"></a>Transformations</h4><p>Any coordinates or lengths supplied to drawing commends are
transformed by a <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>’s current transformation matrix. The
transformation matrix can scale an image, draw it at an offset, or
rotate all drawing. The transformation can be set directly, or the
current transformation can be transformed further with methods like
<span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._scale%29%29" class="RktValLink" data-pltdoc="x">scale</a></span>, <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._translate%29%29" class="RktValLink" data-pltdoc="x">translate</a></span>, or <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._rotate%29%29" class="RktValLink" data-pltdoc="x">rotate</a></span>:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._erase%29%29" class="RktValLink" data-pltdoc="x">erase</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._scale%29%29" class="RktValLink" data-pltdoc="x">scale</a></span><span class="hspace"> </span><span class="RktVal">0.5</span><span class="hspace"> </span><span class="RktVal">0.5</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym">draw-face</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._rotate%29%29" class="RktValLink" data-pltdoc="x">rotate</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252F%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">/</a></span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._translate%29%29" class="RktValLink" data-pltdoc="x">translate</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">150</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym">draw-face</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._translate%29%29" class="RktValLink" data-pltdoc="x">translate</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal"><span class="nobreak">-1</span>50</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._rotate%29%29" class="RktValLink" data-pltdoc="x">rotate</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252F%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">/</a></span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._translate%29%29" class="RktValLink" data-pltdoc="x">translate</a></span><span class="hspace"> </span><span class="RktVal">150</span><span class="hspace"> </span><span class="RktVal">150</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym">draw-face</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._translate%29%29" class="RktValLink" data-pltdoc="x">translate</a></span><span class="hspace"> </span><span class="RktVal"><span class="nobreak">-1</span>50</span><span class="hspace"> </span><span class="RktVal"><span class="nobreak">-1</span>50</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._rotate%29%29" class="RktValLink" data-pltdoc="x">rotate</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252F%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">/</a></span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._translate%29%29" class="RktValLink" data-pltdoc="x">translate</a></span><span class="hspace"> </span><span class="RktVal">150</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym">draw-face</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr></table></blockquote><p>Use the <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._get-transformation%29%29" class="RktValLink" data-pltdoc="x">get-transformation</a></span> method to get a <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>’s
current transformation, and restore a saved transformation (or any
affine transformation) using <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-transformation%29%29" class="RktValLink" data-pltdoc="x">set-transformation</a></span>.</p><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_10.png" alt="image" width="150" height="150"/></span></p></blockquote><h4 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""Drawing_Paths"">1.4<tt> </tt><a name="(part._.Drawing_.Paths)"></a>Drawing Paths</h4><p>Drawing functions like <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-line%29%29" class="RktValLink" data-pltdoc="x">draw-line</a></span> and <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span>
are actually convenience functions for the more general
<span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span> operation. The <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span> operation takes
a <a name="(tech._path)"></a><span style="font-style: italic">path</span>, which describes a set of line segments and curves
to draw with the pen and—<wbr></wbr>in the case of closed set of lines and
curves—<wbr></wbr>fill with the current brush.</p><p>An instance of <span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span> holds a path. Conceptually, a path
has a current pen position that is manipulated by methods like
<span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._move-to%29%29" class="RktValLink" data-pltdoc="x">move-to</a></span>, <span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span>, and <span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span>. The
<span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._move-to%29%29" class="RktValLink" data-pltdoc="x">move-to</a></span> method starts a sub-path, and <span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span> and
<span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span> extend it. The <span class="RktSym">close</span> method moves the pen
from its current position in a straight line to its starting
position, completing the sub-path and forming a closed path that can
be filled with the brush. A <span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span> object can have
multiple closed sub-paths and one final open path, where the open
path is drawn only with the pen.</p><p>For example,</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">zee</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">zee</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._move-to%29%29" class="RktValLink" data-pltdoc="x">move-to</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">zee</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">zee</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">zee</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr></table></blockquote><p>creates an open path. Drawing this path with a black pen of width 5
and a transparent brush produces</p><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_11.png" alt="image" width="40" height="40"/></span></p></blockquote><p>Drawing a single path with three line segments is not the same as
drawing three separate lines. When multiple line segments are drawn at
once, the corner from one line to the next is shaped according to the
pen’s join style. The image above uses the default <span class="RktVal">'</span><span class="RktVal">round</span>
join style. With <span class="RktVal">'</span><span class="RktVal">miter</span>, line lines are joined with sharp
corners:</p><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_12.png" alt="image" width="40" height="40"/></span></p></blockquote><p>If the sub-path in <span class="RktSym">zee</span> is closed with <span class="RktSym">close</span>, then
all of the corners are joined, including the corner at the initial
point:</p><blockquote class="SCodeFlow"><p><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">zee</span><span class="hspace"> </span><span class="RktSym">close</span><span class="RktPn">)</span></p></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_13.png" alt="image" width="40" height="40"/></span></p></blockquote><p>Using <span class="RktSym">blue-brush</span> instead of a transparent brush causes the
interior of the path to be filled:</p><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_14.png" alt="image" width="40" height="40"/></span></p></blockquote><p>When a sub-path is not closed, it is implicitly closed for brush
filling, but left open for pen drawing. When both a pen and brush are
available (i.e., not transparent), then the brush is used first, so
that the pen draws on top of the brush.</p><p>At this point we can’t resist showing an extended example using
<span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span> to draw the Racket logo:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">red-brush</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="brush_.html" class="RktValLink" data-pltdoc="x">brush%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">stipple</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._read-bitmap%29%29" class="RktValLink" data-pltdoc="x">read-bitmap</a></span><span class="hspace"> </span><span class="RktVal">"fire.png"</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">left-lambda-path</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._move-to%29%29" class="RktValLink" data-pltdoc="x">move-to</a></span><span class="hspace"> </span><span class="RktVal">153</span><span class="hspace"> </span><span class="RktVal">44</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">161.5</span><span class="hspace"> </span><span class="RktVal">60</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">202.5</span><span class="hspace"> </span><span class="RktVal">49</span><span class="hspace"> </span><span class="RktVal">230</span><span class="hspace"> </span><span class="RktVal">42</span><span class="hspace"> </span><span class="RktVal">245</span><span class="hspace"> </span><span class="RktVal">61</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">280.06</span><span class="hspace"> </span><span class="RktVal">105.41</span><span class="hspace"> </span><span class="RktVal">287.5</span><span class="hspace"> </span><span class="RktVal">141</span><span class="hspace"> </span><span class="RktVal">296.5</span><span class="hspace"> </span><span class="RktVal">186</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">301.12</span><span class="hspace"> </span><span class="RktVal">209.08</span><span class="hspace"> </span><span class="RktVal">299.11</span><span class="hspace"> </span><span class="RktVal">223.38</span><span class="hspace"> </span><span class="RktVal">293.96</span><span class="hspace"> </span><span class="RktVal">244</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">281.34</span><span class="hspace"> </span><span class="RktVal">294.54</span><span class="hspace"> </span><span class="RktVal">259.18</span><span class="hspace"> </span><span class="RktVal">331.61</span><span class="hspace"> </span><span class="RktVal">233.5</span><span class="hspace"> </span><span class="RktVal">375</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">198.21</span><span class="hspace"> </span><span class="RktVal">434.63</span><span class="hspace"> </span><span class="RktVal">164.68</span><span class="hspace"> </span><span class="RktVal">505.6</span><span class="hspace"> </span><span class="RktVal">125.5</span><span class="hspace"> </span><span class="RktVal">564</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">135</span><span class="hspace"> </span><span class="RktVal">572</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktSym">p</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">left-logo-path</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._append%29%29" class="RktValLink" data-pltdoc="x">append</a></span><span class="hspace"> </span><span class="RktSym">left-lambda-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._arc%29%29" class="RktValLink" data-pltdoc="x">arc</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">630</span><span class="hspace"> </span><span class="RktVal">630</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">47/72</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">121/360</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">#f</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktSym">p</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">bottom-lambda-path</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._move-to%29%29" class="RktValLink" data-pltdoc="x">move-to</a></span><span class="hspace"> </span><span class="RktVal">135</span><span class="hspace"> </span><span class="RktVal">572</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">188.5</span><span class="hspace"> </span><span class="RktVal">564</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">208.5</span><span class="hspace"> </span><span class="RktVal">517</span><span class="hspace"> </span><span class="RktVal">230.91</span><span class="hspace"> </span><span class="RktVal">465.21</span><span class="hspace"> </span><span class="RktVal">251</span><span class="hspace"> </span><span class="RktVal">420</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">267</span><span class="hspace"> </span><span class="RktVal">384</span><span class="hspace"> </span><span class="RktVal">278.5</span><span class="hspace"> </span><span class="RktVal">348</span><span class="hspace"> </span><span class="RktVal">296.5</span><span class="hspace"> </span><span class="RktVal">312</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">301.01</span><span class="hspace"> </span><span class="RktVal">302.98</span><span class="hspace"> </span><span class="RktVal">318</span><span class="hspace"> </span><span class="RktVal">258</span><span class="hspace"> </span><span class="RktVal">329</span><span class="hspace"> </span><span class="RktVal">274</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">338.89</span><span class="hspace"> </span><span class="RktVal">288.39</span><span class="hspace"> </span><span class="RktVal">351</span><span class="hspace"> </span><span class="RktVal">314</span><span class="hspace"> </span><span class="RktVal">358</span><span class="hspace"> </span><span class="RktVal">332</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">377.28</span><span class="hspace"> </span><span class="RktVal">381.58</span><span class="hspace"> </span><span class="RktVal">395.57</span><span class="hspace"> </span><span class="RktVal">429.61</span><span class="hspace"> </span><span class="RktVal">414</span><span class="hspace"> </span><span class="RktVal">477</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">428</span><span class="hspace"> </span><span class="RktVal">513</span><span class="hspace"> </span><span class="RktVal">436.5</span><span class="hspace"> </span><span class="RktVal">540</span><span class="hspace"> </span><span class="RktVal">449.5</span><span class="hspace"> </span><span class="RktVal">573</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">465</span><span class="hspace"> </span><span class="RktVal">580</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">529</span><span class="hspace"> </span><span class="RktVal">545</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktSym">p</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">bottom-logo-path</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._append%29%29" class="RktValLink" data-pltdoc="x">append</a></span><span class="hspace"> </span><span class="RktSym">bottom-lambda-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._arc%29%29" class="RktValLink" data-pltdoc="x">arc</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">630</span><span class="hspace"> </span><span class="RktVal">630</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">157/180</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">47/72</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">#f</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktSym">p</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">right-lambda-path</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._move-to%29%29" class="RktValLink" data-pltdoc="x">move-to</a></span><span class="hspace"> </span><span class="RktVal">153</span><span class="hspace"> </span><span class="RktVal">44</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">192.21</span><span class="hspace"> </span><span class="RktVal">30.69</span><span class="hspace"> </span><span class="RktVal">233.21</span><span class="hspace"> </span><span class="RktVal">14.23</span><span class="hspace"> </span><span class="RktVal">275</span><span class="hspace"> </span><span class="RktVal">20</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">328.6</span><span class="hspace"> </span><span class="RktVal">27.4</span><span class="hspace"> </span><span class="RktVal">350.23</span><span class="hspace"> </span><span class="RktVal">103.08</span><span class="hspace"> </span><span class="RktVal">364</span><span class="hspace"> </span><span class="RktVal">151</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">378.75</span><span class="hspace"> </span><span class="RktVal">202.32</span><span class="hspace"> </span><span class="RktVal">400.5</span><span class="hspace"> </span><span class="RktVal">244</span><span class="hspace"> </span><span class="RktVal">418</span><span class="hspace"> </span><span class="RktVal">294</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span><span class="hspace"> </span><span class="RktVal">446.56</span><span class="hspace"> </span><span class="RktVal">375.6</span><span class="hspace"> </span><span class="RktVal">494.5</span><span class="hspace"> </span><span class="RktVal">456</span><span class="hspace"> </span><span class="RktVal">530.5</span><span class="hspace"> </span><span class="RktVal">537</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span><span class="hspace"> </span><span class="RktVal">529</span><span class="hspace"> </span><span class="RktVal">545</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktSym">p</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">right-logo-path</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._append%29%29" class="RktValLink" data-pltdoc="x">append</a></span><span class="hspace"> </span><span class="RktSym">right-lambda-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._arc%29%29" class="RktValLink" data-pltdoc="x">arc</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">630</span><span class="hspace"> </span><span class="RktVal">630</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">157/180</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">121/360</span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528lib._racket%252Fmath..rkt%2529._pi%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">pi</a></span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">#t</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktSym">p</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">lambda-path</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._append%29%29" class="RktValLink" data-pltdoc="x">append</a></span><span class="hspace"> </span><span class="RktSym">left-lambda-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._append%29%29" class="RktValLink" data-pltdoc="x">append</a></span><span class="hspace"> </span><span class="RktSym">bottom-lambda-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">t</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">t</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._append%29%29" class="RktValLink" data-pltdoc="x">append</a></span><span class="hspace"> </span><span class="RktSym">right-lambda-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">t</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._reverse%29%29" class="RktValLink" data-pltdoc="x">reverse</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._append%29%29" class="RktValLink" data-pltdoc="x">append</a></span><span class="hspace"> </span><span class="RktSym">t</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym">close</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktSym">p</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">paint-racket</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktVal">"black"</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">transparent</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktVal">"white"</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span><span class="hspace"> </span><span class="RktSym">lambda-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktVal">"black"</span><span class="hspace"> </span><span class="RktVal">4</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktSym">red-brush</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span><span class="hspace"> </span><span class="RktSym">left-logo-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span><span class="hspace"> </span><span class="RktSym">bottom-logo-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktSym">blue-brush</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span><span class="hspace"> </span><span class="RktSym">right-logo-path</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">racket-logo</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span><span class="hspace"> </span><span class="RktVal">170</span><span class="hspace"> </span><span class="RktVal">170</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">bitmap</span><span class="hspace"> </span><span class="RktSym">racket-logo</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-smoothing%29%29" class="RktValLink" data-pltdoc="x">set-smoothing</a></span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">smoothed</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._translate%29%29" class="RktValLink" data-pltdoc="x">translate</a></span><span class="hspace"> </span><span class="RktVal">5</span><span class="hspace"> </span><span class="RktVal">5</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._scale%29%29" class="RktValLink" data-pltdoc="x">scale</a></span><span class="hspace"> </span><span class="RktVal">0.25</span><span class="hspace"> </span><span class="RktVal">0.25</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym">paint-racket</span><span class="hspace"> </span><span class="RktSym">dc</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_15.png" alt="image" width="170" height="170"/></span></p></blockquote><p>In addition to the core <span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._move-to%29%29" class="RktValLink" data-pltdoc="x">move-to</a></span>, <span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._line-to%29%29" class="RktValLink" data-pltdoc="x">line-to</a></span>,
<span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._curve-to%29%29" class="RktValLink" data-pltdoc="x">curve-to</a></span>, and <span class="RktSym">close</span> methods, a <span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span>
includes many convenience methods, such as <span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._ellipse%29%29" class="RktValLink" data-pltdoc="x">ellipse</a></span> for adding
a closed elliptical sub-path to the path.</p><h4 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""Text"">1.5<tt> </tt><a name="(part._.Text)"></a>Text</h4><p>Draw text using the <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-text%29%29" class="RktValLink" data-pltdoc="x">draw-text</a></span> method, which takes a string to
draw and a location for the top-left of the drawn text:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">text-target</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">bitmap</span><span class="hspace"> </span><span class="RktSym">text-target</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktVal">"white"</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">transparent</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-text%29%29" class="RktValLink" data-pltdoc="x">draw-text</a></span><span class="hspace"> </span><span class="RktVal">"Hello, World!"</span><span class="hspace"> </span><span class="RktVal">5</span><span class="hspace"> </span><span class="RktVal">1</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_16.png" alt="image" width="100" height="30"/></span></p></blockquote><p>The font used to draw text is determined by the <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>’s current
font. A font is described by a <span class="RktSym"><a href="font_.html" class="RktValLink" data-pltdoc="x">font%</a></span> object and installed
with <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-font%29%29" class="RktValLink" data-pltdoc="x">set-font</a></span>. The color of drawn text which is separate from
either the pen or brush, can be set using
<span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-text-foreground%29%29" class="RktValLink" data-pltdoc="x">set-text-foreground</a></span>.</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._erase%29%29" class="RktValLink" data-pltdoc="x">erase</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-font%29%29" class="RktValLink" data-pltdoc="x">set-font</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-font%29%29" class="RktValLink" data-pltdoc="x">make-font</a></span><span class="hspace"> </span><span class="RktPn">#:size</span><span class="hspace"> </span><span class="RktVal">14</span><span class="hspace"> </span><span class="RktPn">#:family</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">roman</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">#:weight</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">bold</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-text-foreground%29%29" class="RktValLink" data-pltdoc="x">set-text-foreground</a></span><span class="hspace"> </span><span class="RktVal">"blue"</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-text%29%29" class="RktValLink" data-pltdoc="x">draw-text</a></span><span class="hspace"> </span><span class="RktVal">"Hello, World!"</span><span class="hspace"> </span><span class="RktVal">5</span><span class="hspace"> </span><span class="RktVal">1</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_17.png" alt="image" width="100" height="30"/></span></p></blockquote><p>To compute the size that will be used by drawn text, use
<span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._get-text-extent%29%29" class="RktValLink" data-pltdoc="x">get-text-extent</a></span>, which returns four values: the total width,
total height, difference between the baseline and total height, and
extra space (if any) above the text in a line. For example, the result
of <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._get-text-extent%29%29" class="RktValLink" data-pltdoc="x">get-text-extent</a></span> can be used to position text within the
center of a box:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._erase%29%29" class="RktValLink" data-pltdoc="x">erase</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528quote._%7E23%7E25kernel%2529._define-values%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define-values</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">w</span><span class="hspace"> </span><span class="RktSym">h</span><span class="hspace"> </span><span class="RktSym">d</span><span class="hspace"> </span><span class="RktSym">a</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._get-text-extent%29%29" class="RktValLink" data-pltdoc="x">get-text-extent</a></span><span class="hspace"> </span><span class="RktVal">"Hello, World!"</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-text%29%29" class="RktValLink" data-pltdoc="x">draw-text</a></span><span class="hspace"> </span><span class="RktVal">"Hello, World!"</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252F%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">/</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._-%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x"><span class="nobreak">-</span></a></span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktSym">w</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252F%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">/</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._-%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x"><span class="nobreak">-</span></a></span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktSym">h</span><span class="RktPn">)</span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_18.png" alt="image" width="100" height="30"/></span></p></blockquote><h4 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""Alpha_Channels_and_Alpha_Blending"">1.6<tt> </tt><a name="(part._.Alpha_.Channels_and_.Alpha_.Blending)"></a>Alpha Channels and Alpha Blending</h4><p>When you create or <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._erase%29%29" class="RktValLink" data-pltdoc="x">erase</a></span> a bitmap, the content is
nothing. “Nothing” isn’t the same as white; it’s the absence of
drawing. For example, if you take <span class="RktSym">text-target</span> from the
previous section and copy it onto another <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a> using
<span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-bitmap%29%29" class="RktValLink" data-pltdoc="x">draw-bitmap</a></span>, then the black rectangle and blue text is
transferred, and the background is left alone:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">new-target</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">bitmap</span><span class="hspace"> </span><span class="RktSym">new-target</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktVal">"black"</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">transparent</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktVal">"pink"</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-bitmap%29%29" class="RktValLink" data-pltdoc="x">draw-bitmap</a></span><span class="hspace"> </span><span class="RktSym">text-target</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_19.png" alt="image" width="100" height="30"/></span></p></blockquote><p>The information about which pixels of a bitmap are drawn (as opposed
to “nothing”) is the bitmap’s <a name="(tech._alpha._channel)"></a><span style="font-style: italic">alpha channel</span>. Not all
<a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>s keep an alpha channel, but bitmaps created with
<span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span> keep an alpha channel by default. Bitmaps loaded
with <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._read-bitmap%29%29" class="RktValLink" data-pltdoc="x">read-bitmap</a></span> preserve transparency in the image file
through the bitmap’s alpha channel.</p><p>An alpha channel isn’t all or nothing. When the edges text is
anti-aliased by <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-text%29%29" class="RktValLink" data-pltdoc="x">draw-text</a></span>, for example, the pixels are
partially transparent. When the pixels are transferred to another
<a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>, the partially transparent pixel is blended with the target
pixel in a process called <a name="(tech._alpha._blending)"></a><span style="font-style: italic">alpha blending</span>. Furthermore, a
<a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a> has an alpha value that is applied to all drawing
operations; an alpha value of <span class="RktVal">1.0</span> corresponds to solid
drawing, an alpha value of <span class="RktVal">0.0</span> makes the drawing have no
effect, and values in between make the drawing translucent.</p><p>For example, setting the <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>’s alpha to <span class="RktVal">0.25</span> before
calling <span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-bitmap%29%29" class="RktValLink" data-pltdoc="x">draw-bitmap</a></span> causes the blue and black of the “Hello,
World!” bitmap to be quarter strength as it is blended with the
destination image:</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._erase%29%29" class="RktValLink" data-pltdoc="x">erase</a></span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-alpha%29%29" class="RktValLink" data-pltdoc="x">set-alpha</a></span><span class="hspace"> </span><span class="RktVal">0.25</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-bitmap%29%29" class="RktValLink" data-pltdoc="x">draw-bitmap</a></span><span class="hspace"> </span><span class="RktSym">text-target</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_20.png" alt="image" width="100" height="30"/></span></p></blockquote><h4 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""Clipping"">1.7<tt> </tt><a name="(part._.Clipping)"></a>Clipping</h4><p>In addition to tempering the opacity of drawing operations, a
<a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a> has a <a name="(tech._clipping._region)"></a><span style="font-style: italic">clipping region</span> that constrains all drawing to
inside the region. In the simplest case, a clipping region corresponds
to a closed path, but it can also be the union, intersection,
subtraction, or exclusive-or of two paths.</p><p>For example, a clipping region could be set to three circles to clip
the drawing of a rectangle (with the 0.25 alpha still in effect):</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">r</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="region_.html" class="RktValLink" data-pltdoc="x">region%</a></span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fletstx-scheme..rkt%2529._let%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._ellipse%29%29" class="RktValLink" data-pltdoc="x">ellipse</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">35</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._ellipse%29%29" class="RktValLink" data-pltdoc="x">ellipse</a></span><span class="hspace"> </span><span class="RktVal">35</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">30</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc-path~25%29._ellipse%29%29" class="RktValLink" data-pltdoc="x">ellipse</a></span><span class="hspace"> </span><span class="RktVal">65</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">35</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">r</span><span class="hspace"> </span><span class="RktSym"><a href="region_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._region~25%29._set-path%29%29" class="RktValLink" data-pltdoc="x">set-path</a></span><span class="hspace"> </span><span class="RktSym">p</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-clipping-region%29%29" class="RktValLink" data-pltdoc="x">set-clipping-region</a></span><span class="hspace"> </span><span class="RktSym">r</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktVal">"green"</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">100</span><span class="hspace"> </span><span class="RktVal">30</span><span class="RktPn">)</span></td></tr></table></blockquote><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_21.png" alt="image" width="100" height="30"/></span></p></blockquote><p>The clipping region can be viewed as a convenient alternative to path
filling or drawing with stipples. Conversely, stippled drawing can be
viewed as a convenience alternative to clipping repeated calls of
<span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-bitmap%29%29" class="RktValLink" data-pltdoc="x">draw-bitmap</a></span>.</p><p>Combining regions with <span class="RktSym"><a href="pen_.html" class="RktValLink" data-pltdoc="x">pen%</a></span> objects that have gradients, however,
is more than just a convenience, as it allows us to draw shapes in combinations
we could not otherwise draw. To illustrate, here is some code that draws
text with its reflection below it.</p><blockquote class="SCodeFlow"><table cellspacing="0" cellpadding="0" class="RktBlk"><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">First compute the size of the text we're going to draw,</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">using a small bitmap that we never draw into.</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="bitmap-dc_.html" class="RktValLink" data-pltdoc="x">bitmap-dc%</a></span><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">bitmap</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">1</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">str</span><span class="hspace"> </span><span class="RktVal">"Racketeers, ho!"</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">the-font</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-font%29%29" class="RktValLink" data-pltdoc="x">make-font</a></span><span class="hspace"> </span><span class="RktPn">#:size</span><span class="hspace"> </span><span class="RktVal">24</span><span class="hspace"> </span><span class="RktPn">#:family</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">swiss</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">#:weight</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">bold</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528quote._%7E23%7E25kernel%2529._define-values%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define-values</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym">tw</span><span class="hspace"> </span><span class="RktSym">th</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=let.html%23%2528form._%2528%2528quote._%7E23%7E25kernel%2529._let-values%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">let-values</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktPn">[</span><span class="RktPn">(</span><span class="RktSym">tw</span><span class="hspace"> </span><span class="RktSym">th</span><span class="hspace"> </span><span class="RktSym">ta</span><span class="hspace"> </span><span class="RktSym">td</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">dc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._get-text-extent%29%29" class="RktValLink" data-pltdoc="x">get-text-extent</a></span><span class="hspace"> </span><span class="RktSym">str</span><span class="hspace"> </span><span class="RktSym">the-font</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=values.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._values%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">values</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=number-types.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._inexact-%7E3eexact%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">inexact->exact</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._ceiling%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">ceiling</a></span><span class="hspace"> </span><span class="RktSym">tw</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=number-types.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._inexact-%7E3eexact%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">inexact->exact</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._ceiling%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">ceiling</a></span><span class="hspace"> </span><span class="RktSym">th</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">Now we can create a correctly sized bitmap to</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">actually draw into and enable smoothing.</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktSym">set-bitmap</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span><span class="hspace"> </span><span class="RktSym">tw</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktSym">th</span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-smoothing%29%29" class="RktValLink" data-pltdoc="x">set-smoothing</a></span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">smoothed</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">next, build a path that contains the outline of the text</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">upper-path</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">upper-path</span><span class="hspace"> </span><span class="RktSym">text-outline</span><span class="hspace"> </span><span class="RktSym">the-font</span><span class="hspace"> </span><span class="RktSym">str</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">next, build a path that contains the mirror image</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">outline of the text</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">lower-path</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="dc-path_.html" class="RktValLink" data-pltdoc="x">dc-path%</a></span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">lower-path</span><span class="hspace"> </span><span class="RktSym">text-outline</span><span class="hspace"> </span><span class="RktSym">the-font</span><span class="hspace"> </span><span class="RktSym">str</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">lower-path</span><span class="hspace"> </span><span class="RktSym">transform</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=vectors.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._vector%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">vector</a></span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal"><span class="nobreak">-1</span></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">lower-path</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._translate%29%29" class="RktValLink" data-pltdoc="x">translate</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktVal">2</span><span class="hspace"> </span><span class="RktSym">th</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">This helper accepts a path, sets the clipping region</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">of bdc to be the path (but in region form), and then</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">draws a big rectangle over the whole bitmap.</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">The brush will be set differently before each call to</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">draw-path, in order to draw the text and then to draw</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">the shadow.</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span><span class="hspace"> </span><span class="RktSym">path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">rgn</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="region_.html" class="RktValLink" data-pltdoc="x">region%</a></span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">rgn</span><span class="hspace"> </span><span class="RktSym"><a href="region_.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._region~25%29._set-path%29%29" class="RktValLink" data-pltdoc="x">set-path</a></span><span class="hspace"> </span><span class="RktSym">path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-clipping-region%29%29" class="RktValLink" data-pltdoc="x">set-clipping-region</a></span><span class="hspace"> </span><span class="RktSym">rgn</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-pen%29%29" class="RktValLink" data-pltdoc="x">set-pen</a></span><span class="hspace"> </span><span class="RktVal">"white"</span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">transparent</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-rectangle%29%29" class="RktValLink" data-pltdoc="x">draw-rectangle</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktSym">tw</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktSym">th</span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-clipping-region%29%29" class="RktValLink" data-pltdoc="x">set-clipping-region</a></span><span class="hspace"> </span><span class="RktVal">#f</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">Now we just draw the upper-path with a solid brush</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span><span class="hspace"> </span><span class="RktVal">"black"</span><span class="hspace"> </span><span class="RktVal">'</span><span class="RktVal">solid</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span><span class="hspace"> </span><span class="RktSym">upper-path</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">To draw the shadow, we set up a brush that has a</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">linear gradient over the portion of the bitmap</span></td></tr><tr><td><span class="RktCmt">;</span><span class="RktCmt"> </span><span class="RktCmt">where the shadow goes</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=define.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fbase..rkt%2529._define%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">define</a></span><span class="hspace"> </span><span class="RktSym">stops</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=pairs.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._list%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">list</a></span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=pairs.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._list%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">list</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-color%29%29" class="RktValLink" data-pltdoc="x">make-color</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0.4</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=pairs.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._list%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">list</a></span><span class="hspace"> </span><span class="RktVal">1</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-color%29%29" class="RktValLink" data-pltdoc="x">make-color</a></span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="hspace"> </span><span class="RktVal">0.0</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=ivaraccess.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._send%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">send</a></span><span class="hspace"> </span><span class="RktSym">bdc</span><span class="hspace"> </span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._set-brush%29%29" class="RktValLink" data-pltdoc="x">set-brush</a></span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="brush_.html" class="RktValLink" data-pltdoc="x">brush%</a></span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">gradient</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=objcreation.html%23%2528form._%2528%2528lib._racket%252Fprivate%252Fclass-internal..rkt%2529._new%2529%2529&version=6.7" class="RktStxLink Sq" data-pltdoc="x">new</a></span><span class="hspace"> </span><span class="RktSym"><a href="linear-gradient_.html" class="RktValLink" data-pltdoc="x">linear-gradient%</a></span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">x0</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">]</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">y0</span><span class="hspace"> </span><span class="RktSym">th</span><span class="RktPn">]</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">x1</span><span class="hspace"> </span><span class="RktVal">0</span><span class="RktPn">]</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">y1</span><span class="hspace"> </span><span class="RktPn">(</span><span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=reference&rel=generic-numbers.html%23%2528def._%2528%2528quote._%7E23%7E25kernel%2529._%252A%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">*</a></span><span class="hspace"> </span><span class="RktSym">th</span><span class="hspace"> </span><span class="RktVal">2</span><span class="RktPn">)</span><span class="RktPn">]</span></td></tr><tr><td><span class="hspace"> </span><span class="RktPn">[</span><span class="RktSym">stops</span><span class="hspace"> </span><span class="RktSym">stops</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">]</span><span class="RktPn">)</span><span class="RktPn">)</span></td></tr><tr><td><span class="RktPn">(</span><span class="RktSym"><a href="dc___.html#%28meth._%28%28%28lib._racket%2Fdraw..rkt%29._dc~3c~25~3e%29._draw-path%29%29" class="RktValLink" data-pltdoc="x">draw-path</a></span><span class="hspace"> </span><span class="RktSym">lower-path</span><span class="RktPn">)</span></td></tr></table></blockquote><p>And now the bitmap in <span class="RktSym">bdc</span> has “Racketeers, ho!” with
a mirrored version below it.</p><blockquote class="SCentered"><p><span class="RktRes"><img src="pict_22.png" alt="image" width="286" height="76"/></span></p></blockquote><h4 x-source-module="(lib "scribblings/draw/draw.scrbl")" x-source-pkg="draw-doc" x-part-tag=""Portability"">1.8<tt> </tt><a name="(part._.Portability)"></a>Portability and Bitmap Variants</h4><p>Drawing effects are not completely portable across platforms, across
different classes that implement <span class="RktSym"><a href="dc___.html" class="RktValLink" data-pltdoc="x">dc<%></a></span>, or different
kinds of bitmaps. Fonts and text, especially, can vary across
platforms and types of <a href="#%28tech._dc%29" class="techoutside" data-pltdoc="x"><span class="techinside">DC</span></a>, but so can the precise set of pixels
touched by drawing a line.</p><p>Different kinds of bitmaps can produce different results:</p><ul><li><p>Drawing to a bitmap produced by <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span> (or
instantiated from <span class="RktSym"><a href="bitmap_.html" class="RktValLink" data-pltdoc="x">bitmap%</a></span>) draws in the most
consistent way across platforms.</p></li><li><p>Drawing to a bitmap produced by <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-platform-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-platform-bitmap</a></span>
uses platform-specific drawing operations as much as possible.
On Windows, however, a bitmap produced by
<span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-platform-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-platform-bitmap</a></span> has no alpha channel, and it uses
more constrained resources than one produced by
<span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span> (due to a system-wide, per-process GDI limit).</p><p>As an example of platform-specific difference, text is smoothed
by default with sub-pixel anti-aliasing on Mac OS X, while text
smoothing in a <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span> result uses only grays.
Line or curve drawing may touch different pixels than in a
bitmap produced by <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span>, and bitmap scaling may
differ.</p><p>A possible approach to dealing with the GDI limit under Windows
is to draw into the result of a <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-platform-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-platform-bitmap</a></span>
and then copy the contents of the drawing into the result of a
<span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-bitmap</a></span>. This approach preserves the drawing
results of <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-platform-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-platform-bitmap</a></span>, but it retains
constrained resources only during the drawing process.</p></li><li><p>Drawing to a bitmap produced by <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=Windowing_Functions.html%23%2528def._%2528%2528lib._mred%252Fmain..rkt%2529._make-screen-bitmap%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-screen-bitmap</a></span>
from <a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=index.html&version=6.7" class="RktModLink Sq" data-pltdoc="x"><span class="RktSym">racket/gui/base</span></a> uses the same
platform-specific drawing operations as drawing into a
<span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=canvas_.html&version=6.7" class="RktValLink Sq" data-pltdoc="x">canvas%</a></span> instance. A bitmap produced by
<span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=Windowing_Functions.html%23%2528def._%2528%2528lib._mred%252Fmain..rkt%2529._make-screen-bitmap%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-screen-bitmap</a></span> uses the same platform-specific
drawing as <span class="RktSym"><a href="Drawing_Functions.html#%28def._%28%28lib._racket%2Fdraw..rkt%29._make-platform-bitmap%29%29" class="RktValLink" data-pltdoc="x">make-platform-bitmap</a></span> on Windows or Mac OS
X, but possibly scaled, and it may be scaled or sensitive to the X11
server on Unix.</p><p>On Mac OS X, when the main screen is in Retina mode (at the
time that the bitmap is created), the bitmap is also internally
scaled so that one drawing unit uses two pixels. Similarly, on
Windows or Unix, when the main display’s text scale is configured at
the operating-system level (see <a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=windowing-overview.html%23%2528part._display-resolution%2529&version=6.7" class="Sq" data-pltdoc="x">Screen Resolution and Text Scaling</a>), the bitmap
is internally scaled, where common configurations map a drawing
unit to <span style="font-style: italic"></span>1<span style="font-style: italic">.</span>2<span style="font-style: italic"></span>5<span style="font-style: italic"></span>, <span style="font-style: italic"></span>1<span style="font-style: italic">.</span>5<span style="font-style: italic"></span>, or <span style="font-style: italic"></span>2<span style="font-style: italic"></span> pixels.</p><p>Use <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=Windowing_Functions.html%23%2528def._%2528%2528lib._mred%252Fmain..rkt%2529._make-screen-bitmap%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-screen-bitmap</a></span> when drawing to a bitmap as an
offscreen buffer before transferring an image to the screen, or
when consistency with screen drawing is needed for some other
reason.</p></li><li><p>A bitmap produced by <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=canvas_.html%23%2528meth._%2528%2528%2528lib._mred%252Fmain..rkt%2529._canvas%7E25%2529._make-bitmap%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-bitmap</a></span> in <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=canvas_.html&version=6.7" class="RktValLink Sq" data-pltdoc="x">canvas%</a></span> from
<a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=index.html&version=6.7" class="RktModLink Sq" data-pltdoc="x"><span class="RktSym">racket/gui/base</span></a> is like a bitmap from
<span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=Windowing_Functions.html%23%2528def._%2528%2528lib._mred%252Fmain..rkt%2529._make-screen-bitmap%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-screen-bitmap</a></span>, but on Mac OS X, the bitmap is
optimized for drawing to the screen (by taking advantage of
system APIs that can, in turn, take advantage of graphics
hardware).</p><p>Use <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=canvas_.html%23%2528meth._%2528%2528%2528lib._mred%252Fmain..rkt%2529._canvas%7E25%2529._make-bitmap%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-bitmap</a></span> in <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=canvas_.html&version=6.7" class="RktValLink Sq" data-pltdoc="x">canvas%</a></span> for similar purposes
as <span class="RktSym"><a href="https://download.racket-lang.org/docs/6.7/html/local-redirect/index.html?doc=gui&rel=Windowing_Functions.html%23%2528def._%2528%2528lib._mred%252Fmain..rkt%2529._make-screen-bitmap%2529%2529&version=6.7" class="RktValLink Sq" data-pltdoc="x">make-screen-bitmap</a></span>, particularly when the bitmap
will be drawn later to a known target canvas.</p></li></ul><div class="navsetbottom"><span class="navleft"><form class="searchform"><input class="searchbox" style="color: #888;" type="text" value="...search manuals..." title="Enter a search string to search the manuals" onkeypress="return DoSearchKey(event, this, "6.7", "../");" onfocus="this.style.color="black"; this.style.textAlign="left"; if (this.value == "...search manuals...") this.value="";" onblur="if (this.value.match(/^ *$/)) { this.style.color="#888"; this.style.textAlign="center"; this.value="...search manuals..."; }"/></form> <a href="../index.html" title="up to the documentation top" data-pltdoc="x" onclick="return GotoPLTRoot("6.7");">top</a></span><span class="navright"> <a href="index.html" title="backward to "The Racket Drawing Toolkit"" data-pltdoc="x">← prev</a> <a href="index.html" title="up to "The Racket Drawing Toolkit"" data-pltdoc="x">up</a> <a href="bitmap_.html" title="forward to "2 bitmap%"" data-pltdoc="x">next →</a></span> </div></div></div><div id="contextindicator"> </div></body></html>
|