index.html 80 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948949950951952953954955956957958959960961962963964965966967968969970971972973974975976977978979980981982983984985986987988989990991992993994995996997998999100010011002100310041005100610071008100910101011101210131014101510161017101810191020102110221023102410251026102710281029103010311032103310341035103610371038103910401041104210431044104510461047104810491050105110521053105410551056105710581059106010611062106310641065106610671068106910701071107210731074107510761077107810791080108110821083108410851086108710881089109010911092109310941095109610971098109911001101110211031104110511061107110811091110111111121113111411151116111711181119112011211122112311241125112611271128112911301131113211331134113511361137113811391140114111421143114411451146114711481149115011511152115311541155115611571158115911601161116211631164116511661167116811691170117111721173117411751176117711781179118011811182118311841185118611871188118911901191119211931194119511961197119811991200120112021203120412051206120712081209121012111212121312141215121612171218121912201221122212231224122512261227122812291230123112321233123412351236123712381239124012411242124312441245124612471248124912501251125212531254125512561257125812591260126112621263126412651266126712681269127012711272127312741275127612771278127912801281128212831284128512861287128812891290129112921293129412951296129712981299130013011302130313041305130613071308130913101311131213131314131513161317131813191320132113221323132413251326132713281329133013311332133313341335133613371338133913401341134213431344134513461347134813491350135113521353135413551356135713581359136013611362136313641365136613671368136913701371137213731374137513761377137813791380138113821383138413851386138713881389139013911392139313941395139613971398139914001401140214031404140514061407140814091410141114121413141414151416141714181419142014211422142314241425142614271428142914301431143214331434143514361437143814391440144114421443144414451446144714481449145014511452145314541455145614571458145914601461146214631464146514661467146814691470147114721473147414751476147714781479148014811482148314841485148614871488148914901491149214931494149514961497149814991500150115021503150415051506150715081509151015111512151315141515151615171518151915201521152215231524152515261527152815291530153115321533153415351536153715381539154015411542154315441545154615471548154915501551155215531554155515561557155815591560156115621563156415651566156715681569157015711572157315741575157615771578157915801581158215831584158515861587158815891590159115921593159415951596159715981599160016011602160316041605160616071608160916101611161216131614161516161617161816191620162116221623162416251626162716281629163016311632163316341635163616371638163916401641164216431644164516461647164816491650165116521653165416551656165716581659166016611662166316641665166616671668166916701671167216731674167516761677167816791680168116821683168416851686168716881689169016911692169316941695169616971698169917001701170217031704170517061707170817091710171117121713171417151716171717181719172017211722172317241725172617271728172917301731173217331734173517361737173817391740174117421743174417451746174717481749175017511752175317541755175617571758175917601761176217631764176517661767176817691770177117721773177417751776177717781779178017811782178317841785178617871788178917901791179217931794179517961797179817991800180118021803180418051806
  1. <!DOCTYPE html>
  2. <!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
  3. <!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
  4. <head>
  5. <meta charset="utf-8">
  6. <meta name="viewport" content="width=device-width, initial-scale=1.0">
  7. <title>Welcome to Cirkuix’s documentation! &mdash; Cirkuix 0.5 documentation</title>
  8. <link href='https://fonts.googleapis.com/css?family=Lato:400,700|Roboto+Slab:400,700|Inconsolata:400,700' rel='stylesheet' type='text/css'>
  9. <script type="text/javascript">
  10. var DOCUMENTATION_OPTIONS = {
  11. URL_ROOT:'./',
  12. VERSION:'0.5',
  13. COLLAPSE_INDEX:false,
  14. FILE_SUFFIX:'.html',
  15. HAS_SOURCE: true
  16. };
  17. </script>
  18. <script type="text/javascript" src="_static/jquery.js"></script>
  19. <script type="text/javascript" src="_static/underscore.js"></script>
  20. <script type="text/javascript" src="_static/doctools.js"></script>
  21. <link rel="stylesheet" href="_static/css/theme.css" type="text/css" />
  22. <script type="text/javascript" src="_static/js/theme.js"></script>
  23. <script type="text/javascript">
  24. jQuery(function () {
  25. SphinxRtdTheme.StickyNav.enable();
  26. });
  27. </script>
  28. <link rel="top" title="Cirkuix 0.5 documentation" href="#"/>
  29. <script src="https://cdnjs.cloudflare.com/ajax/libs/modernizr/2.6.2/modernizr.min.js"></script>
  30. </head>
  31. <body class="wy-body-for-nav" role="document">
  32. <div class="wy-grid-for-nav">
  33. <nav data-toggle="wy-nav-shift" class="wy-nav-side">
  34. <div class="wy-side-nav-search">
  35. <a href="#" class="icon icon-home"> Cirkuix</a>
  36. <div role="search">
  37. <form id ="rtd-search-form" class="wy-form" action="search.html" method="get">
  38. <input type="text" name="q" placeholder="Search docs" />
  39. <input type="hidden" name="check_keywords" value="yes" />
  40. <input type="hidden" name="area" value="default" />
  41. </form>
  42. </div>
  43. </div>
  44. <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
  45. <ul class="simple">
  46. </ul>
  47. </div>
  48. &nbsp;
  49. </nav>
  50. <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
  51. <nav class="wy-nav-top" role="navigation" aria-label="top navigation">
  52. <i data-toggle="wy-nav-top" class="icon icon-reorder"></i>
  53. <a href="#">Cirkuix</a>
  54. </nav>
  55. <div class="wy-nav-content">
  56. <div class="rst-content">
  57. <div role="navigation" aria-label="breadcrumbs navigation">
  58. <ul class="wy-breadcrumbs">
  59. <li><a href="#">Docs</a> &raquo;</li>
  60. <li>Welcome to Cirkuix&#8217;s documentation!</li>
  61. <li class="wy-breadcrumbs-aside">
  62. <a href="_sources/index.txt" rel="nofollow"> View page source</a>
  63. </li>
  64. </ul>
  65. <hr/>
  66. </div>
  67. <div role="main">
  68. <div class="section" id="welcome-to-cirkuix-s-documentation">
  69. <h1>Welcome to Cirkuix&#8217;s documentation!<a class="headerlink" href="#welcome-to-cirkuix-s-documentation" title="Permalink to this headline">¶</a></h1>
  70. <p>Contents:</p>
  71. <div class="toctree-wrapper compound">
  72. <ul class="simple">
  73. </ul>
  74. </div>
  75. <span class="target" id="module-cirkuix"></span><dl class="class">
  76. <dt id="cirkuix.App">
  77. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">App</tt><a class="headerlink" href="#cirkuix.App" title="Permalink to this definition">¶</a></dt>
  78. <dd><p>The main application class. The constructor starts the GUI.</p>
  79. <dl class="method">
  80. <dt id="cirkuix.App.adjust_axes">
  81. <tt class="descname">adjust_axes</tt><big>(</big><em>xmin</em>, <em>ymin</em>, <em>xmax</em>, <em>ymax</em><big>)</big><a class="headerlink" href="#cirkuix.App.adjust_axes" title="Permalink to this definition">¶</a></dt>
  82. <dd><p>Adjusts axes of all plots while maintaining the use of the whole canvas
  83. and an aspect ratio to 1:1 between x and y axes. The parameters are an original
  84. request that will be modified to fit these restrictions.</p>
  85. <table class="docutils field-list" frame="void" rules="none">
  86. <col class="field-name" />
  87. <col class="field-body" />
  88. <tbody valign="top">
  89. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  90. <li><strong>xmin</strong> (<em>float</em>) &#8211; Requested minimum value for the X axis.</li>
  91. <li><strong>ymin</strong> (<em>float</em>) &#8211; Requested minimum value for the Y axis.</li>
  92. <li><strong>xmax</strong> (<em>float</em>) &#8211; Requested maximum value for the X axis.</li>
  93. <li><strong>ymax</strong> (<em>float</em>) &#8211; Requested maximum value for the Y axis.</li>
  94. </ul>
  95. </td>
  96. </tr>
  97. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">None</p>
  98. </td>
  99. </tr>
  100. </tbody>
  101. </table>
  102. </dd></dl>
  103. <dl class="method">
  104. <dt id="cirkuix.App.build_list">
  105. <tt class="descname">build_list</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.build_list" title="Permalink to this definition">¶</a></dt>
  106. <dd><p>Clears and re-populates the list of objects in currently
  107. in the project.</p>
  108. <table class="docutils field-list" frame="void" rules="none">
  109. <col class="field-name" />
  110. <col class="field-body" />
  111. <tbody valign="top">
  112. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  113. </tr>
  114. </tbody>
  115. </table>
  116. </dd></dl>
  117. <dl class="method">
  118. <dt id="cirkuix.App.clear_plots">
  119. <tt class="descname">clear_plots</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.clear_plots" title="Permalink to this definition">¶</a></dt>
  120. <dd><p>Clears self.axes and self.figure.</p>
  121. <table class="docutils field-list" frame="void" rules="none">
  122. <col class="field-name" />
  123. <col class="field-body" />
  124. <tbody valign="top">
  125. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  126. </tr>
  127. </tbody>
  128. </table>
  129. </dd></dl>
  130. <dl class="method">
  131. <dt id="cirkuix.App.file_chooser_action">
  132. <tt class="descname">file_chooser_action</tt><big>(</big><em>on_success</em><big>)</big><a class="headerlink" href="#cirkuix.App.file_chooser_action" title="Permalink to this definition">¶</a></dt>
  133. <dd><p>Opens the file chooser and runs on_success on a separate thread
  134. upon completion of valid file choice.</p>
  135. <table class="docutils field-list" frame="void" rules="none">
  136. <col class="field-name" />
  137. <col class="field-body" />
  138. <tbody valign="top">
  139. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>on_success</strong> (<em>func</em>) &#8211; A function to run upon completion of a valid file
  140. selection. Takes 2 parameters: The app instance and the filename.
  141. Note that it is run on a separate thread, therefore it must take the
  142. appropriate precautions when accessing shared resources.</td>
  143. </tr>
  144. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  145. </tr>
  146. </tbody>
  147. </table>
  148. </dd></dl>
  149. <dl class="method">
  150. <dt id="cirkuix.App.file_chooser_save_action">
  151. <tt class="descname">file_chooser_save_action</tt><big>(</big><em>on_success</em><big>)</big><a class="headerlink" href="#cirkuix.App.file_chooser_save_action" title="Permalink to this definition">¶</a></dt>
  152. <dd><p>Opens the file chooser and runs on_success upon completion of valid file choice.</p>
  153. <table class="docutils field-list" frame="void" rules="none">
  154. <col class="field-name" />
  155. <col class="field-body" />
  156. <tbody valign="top">
  157. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>on_success</strong> &#8211; A function to run upon selection of a filename. Takes 2
  158. parameters: The instance of the application (App) and the chosen filename. This
  159. gets run immediately in the same thread.</td>
  160. </tr>
  161. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  162. </tr>
  163. </tbody>
  164. </table>
  165. </dd></dl>
  166. <dl class="method">
  167. <dt id="cirkuix.App.get_current">
  168. <tt class="descname">get_current</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.get_current" title="Permalink to this definition">¶</a></dt>
  169. <dd><p>Returns the currently selected CirkuixObj in the application.</p>
  170. <table class="docutils field-list" frame="void" rules="none">
  171. <col class="field-name" />
  172. <col class="field-body" />
  173. <tbody valign="top">
  174. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">Currently selected CirkuixObj in the application.</td>
  175. </tr>
  176. <tr class="field-even field"><th class="field-name">Return type:</th><td class="field-body">CirkuixObj or None</td>
  177. </tr>
  178. </tbody>
  179. </table>
  180. </dd></dl>
  181. <dl class="method">
  182. <dt id="cirkuix.App.get_eval">
  183. <tt class="descname">get_eval</tt><big>(</big><em>widget_name</em><big>)</big><a class="headerlink" href="#cirkuix.App.get_eval" title="Permalink to this definition">¶</a></dt>
  184. <dd><p>Runs eval() on the on the text entry of name &#8216;widget_name&#8217;
  185. and returns the results.</p>
  186. <table class="docutils field-list" frame="void" rules="none">
  187. <col class="field-name" />
  188. <col class="field-body" />
  189. <tbody valign="top">
  190. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget_name</strong> (<em>str</em>) &#8211; Name of Gtk.Entry</td>
  191. </tr>
  192. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">Depends on contents of the entry text.</td>
  193. </tr>
  194. </tbody>
  195. </table>
  196. </dd></dl>
  197. <dl class="method">
  198. <dt id="cirkuix.App.get_radio_value">
  199. <tt class="descname">get_radio_value</tt><big>(</big><em>radio_set</em><big>)</big><a class="headerlink" href="#cirkuix.App.get_radio_value" title="Permalink to this definition">¶</a></dt>
  200. <dd><p>Returns the radio_set[key] of the radiobutton
  201. whose name is key is active.</p>
  202. <table class="docutils field-list" frame="void" rules="none">
  203. <col class="field-name" />
  204. <col class="field-body" />
  205. <tbody valign="top">
  206. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>radio_set</strong> (<em>dict</em>) &#8211; A dictionary containing widget_name: value pairs.</td>
  207. </tr>
  208. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">radio_set[key]</td>
  209. </tr>
  210. </tbody>
  211. </table>
  212. </dd></dl>
  213. <dl class="method">
  214. <dt id="cirkuix.App.info">
  215. <tt class="descname">info</tt><big>(</big><em>text</em><big>)</big><a class="headerlink" href="#cirkuix.App.info" title="Permalink to this definition">¶</a></dt>
  216. <dd><p>Show text on the status bar.</p>
  217. <table class="docutils field-list" frame="void" rules="none">
  218. <col class="field-name" />
  219. <col class="field-body" />
  220. <tbody valign="top">
  221. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>text</strong> (<em>str</em>) &#8211; Text to display.</td>
  222. </tr>
  223. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  224. </tr>
  225. </tbody>
  226. </table>
  227. </dd></dl>
  228. <dl class="method">
  229. <dt id="cirkuix.App.load_defaults">
  230. <tt class="descname">load_defaults</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.load_defaults" title="Permalink to this definition">¶</a></dt>
  231. <dd><p>Loads the aplication&#8217;s default settings from defaults.json into
  232. <tt class="docutils literal"><span class="pre">self.defaults</span></tt>.</p>
  233. <table class="docutils field-list" frame="void" rules="none">
  234. <col class="field-name" />
  235. <col class="field-body" />
  236. <tbody valign="top">
  237. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  238. </tr>
  239. </tbody>
  240. </table>
  241. </dd></dl>
  242. <dl class="method">
  243. <dt id="cirkuix.App.new_object">
  244. <tt class="descname">new_object</tt><big>(</big><em>kind</em>, <em>name</em>, <em>initialize</em><big>)</big><a class="headerlink" href="#cirkuix.App.new_object" title="Permalink to this definition">¶</a></dt>
  245. <dd><p>Creates a new specalized CirkuixObj and attaches it to the application,
  246. this is, updates the GUI accordingly, any other records and plots it.</p>
  247. <table class="docutils field-list" frame="void" rules="none">
  248. <col class="field-name" />
  249. <col class="field-body" />
  250. <tbody valign="top">
  251. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  252. <li><strong>kind</strong> (<em>str</em>) &#8211; The kind of object to create. One of &#8216;gerber&#8217;,
  253. &#8216;excellon&#8217;, &#8216;cncjob&#8217; and &#8216;geometry&#8217;.</li>
  254. <li><strong>name</strong> (<em>str</em>) &#8211; Name for the object.</li>
  255. <li><strong>initialize</strong> (<em>function</em>) &#8211; Function to run after creation of the object
  256. but before it is attached to the application. The function is
  257. called with 2 parameters: the new object and the App instance.</li>
  258. </ul>
  259. </td>
  260. </tr>
  261. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first">None</p>
  262. </td>
  263. </tr>
  264. <tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body"><p class="first last">None</p>
  265. </td>
  266. </tr>
  267. </tbody>
  268. </table>
  269. </dd></dl>
  270. <dl class="method">
  271. <dt id="cirkuix.App.on_activate_name">
  272. <tt class="descname">on_activate_name</tt><big>(</big><em>entry</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_activate_name" title="Permalink to this definition">¶</a></dt>
  273. <dd><p>Hitting &#8216;Enter&#8217; after changing the name of an item
  274. updates the item dictionary and re-builds the item list.</p>
  275. <table class="docutils field-list" frame="void" rules="none">
  276. <col class="field-name" />
  277. <col class="field-body" />
  278. <tbody valign="top">
  279. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>entry</strong> &#8211; The widget from which this was called.</td>
  280. </tr>
  281. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  282. </tr>
  283. </tbody>
  284. </table>
  285. </dd></dl>
  286. <dl class="method">
  287. <dt id="cirkuix.App.on_canvas_configure">
  288. <tt class="descname">on_canvas_configure</tt><big>(</big><em>widget</em>, <em>event</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_canvas_configure" title="Permalink to this definition">¶</a></dt>
  289. <dd><p>Called whenever the canvas changes size. The axes are updated such
  290. as to use the whole canvas.</p>
  291. <table class="docutils field-list" frame="void" rules="none">
  292. <col class="field-name" />
  293. <col class="field-body" />
  294. <tbody valign="top">
  295. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  296. <li><strong>widget</strong> &#8211; Ignored.</li>
  297. <li><strong>event</strong> &#8211; Ignored.</li>
  298. </ul>
  299. </td>
  300. </tr>
  301. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">None</p>
  302. </td>
  303. </tr>
  304. </tbody>
  305. </table>
  306. </dd></dl>
  307. <dl class="method">
  308. <dt id="cirkuix.App.on_clear_plots">
  309. <tt class="descname">on_clear_plots</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_clear_plots" title="Permalink to this definition">¶</a></dt>
  310. <dd><p>Callback for toolbar button. Clears all plots.</p>
  311. <table class="docutils field-list" frame="void" rules="none">
  312. <col class="field-name" />
  313. <col class="field-body" />
  314. <tbody valign="top">
  315. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  316. </tr>
  317. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  318. </tr>
  319. </tbody>
  320. </table>
  321. </dd></dl>
  322. <dl class="method">
  323. <dt id="cirkuix.App.on_click_over_plot">
  324. <tt class="descname">on_click_over_plot</tt><big>(</big><em>event</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_click_over_plot" title="Permalink to this definition">¶</a></dt>
  325. <dd><p>Callback for the mouse click event over the plot. This event is generated
  326. by the Matplotlib backend and has been registered in <tt class="docutils literal"><span class="pre">self.__init__()</span></tt>.
  327. For details, see: <a class="reference external" href="http://matplotlib.org/users/event_handling.html">http://matplotlib.org/users/event_handling.html</a></p>
  328. <table class="docutils field-list" frame="void" rules="none">
  329. <col class="field-name" />
  330. <col class="field-body" />
  331. <tbody valign="top">
  332. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>event</strong> &#8211; </td>
  333. </tr>
  334. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
  335. </tr>
  336. </tbody>
  337. </table>
  338. </dd></dl>
  339. <dl class="method">
  340. <dt id="cirkuix.App.on_closewindow">
  341. <tt class="descname">on_closewindow</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_closewindow" title="Permalink to this definition">¶</a></dt>
  342. <dd><p>Callback for closing the main window.</p>
  343. <table class="docutils field-list" frame="void" rules="none">
  344. <col class="field-name" />
  345. <col class="field-body" />
  346. <tbody valign="top">
  347. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Whatever is passed by the event. Ignore.</td>
  348. </tr>
  349. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  350. </tr>
  351. </tbody>
  352. </table>
  353. </dd></dl>
  354. <dl class="method">
  355. <dt id="cirkuix.App.on_cncjob_exportgcode">
  356. <tt class="descname">on_cncjob_exportgcode</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_cncjob_exportgcode" title="Permalink to this definition">¶</a></dt>
  357. <dd><p>Called from button on CNCjob form to save the G-Code from the object.</p>
  358. <table class="docutils field-list" frame="void" rules="none">
  359. <col class="field-name" />
  360. <col class="field-body" />
  361. <tbody valign="top">
  362. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  363. </tr>
  364. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  365. </tr>
  366. </tbody>
  367. </table>
  368. </dd></dl>
  369. <dl class="method">
  370. <dt id="cirkuix.App.on_delete">
  371. <tt class="descname">on_delete</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_delete" title="Permalink to this definition">¶</a></dt>
  372. <dd><p>Delete the currently selected CirkuixObj.</p>
  373. <table class="docutils field-list" frame="void" rules="none">
  374. <col class="field-name" />
  375. <col class="field-body" />
  376. <tbody valign="top">
  377. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  378. </tr>
  379. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  380. </tr>
  381. </tbody>
  382. </table>
  383. </dd></dl>
  384. <dl class="method">
  385. <dt id="cirkuix.App.on_entry_eval_activate">
  386. <tt class="descname">on_entry_eval_activate</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_entry_eval_activate" title="Permalink to this definition">¶</a></dt>
  387. <dd><p>Called when an entry is activated (eg. by hitting enter) if
  388. set to do so. Its text is eval()&#8217;d and set to the returned value.
  389. The current object is updated.</p>
  390. <table class="docutils field-list" frame="void" rules="none">
  391. <col class="field-name" />
  392. <col class="field-body" />
  393. <tbody valign="top">
  394. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; </td>
  395. </tr>
  396. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"></td>
  397. </tr>
  398. </tbody>
  399. </table>
  400. </dd></dl>
  401. <dl class="method">
  402. <dt id="cirkuix.App.on_eval_update">
  403. <tt class="descname">on_eval_update</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_eval_update" title="Permalink to this definition">¶</a></dt>
  404. <dd><p>Modifies the content of a Gtk.Entry by running
  405. eval() on its contents and puting it back as a
  406. string.</p>
  407. <table class="docutils field-list" frame="void" rules="none">
  408. <col class="field-name" />
  409. <col class="field-body" />
  410. <tbody valign="top">
  411. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  412. </tr>
  413. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  414. </tr>
  415. </tbody>
  416. </table>
  417. </dd></dl>
  418. <dl class="method">
  419. <dt id="cirkuix.App.on_excellon_tool_choose">
  420. <tt class="descname">on_excellon_tool_choose</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_excellon_tool_choose" title="Permalink to this definition">¶</a></dt>
  421. <dd><p>Callback for button on Excellon form to open up a window for
  422. selecting tools.</p>
  423. <table class="docutils field-list" frame="void" rules="none">
  424. <col class="field-name" />
  425. <col class="field-body" />
  426. <tbody valign="top">
  427. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  428. </tr>
  429. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  430. </tr>
  431. </tbody>
  432. </table>
  433. </dd></dl>
  434. <dl class="method">
  435. <dt id="cirkuix.App.on_file_new">
  436. <tt class="descname">on_file_new</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_file_new" title="Permalink to this definition">¶</a></dt>
  437. <dd><p>Callback for menu item File-&gt;New. Returns the application to its
  438. startup state.</p>
  439. <table class="docutils field-list" frame="void" rules="none">
  440. <col class="field-name" />
  441. <col class="field-body" />
  442. <tbody valign="top">
  443. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Whatever is passed by the event. Ignore.</td>
  444. </tr>
  445. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  446. </tr>
  447. </tbody>
  448. </table>
  449. </dd></dl>
  450. <dl class="method">
  451. <dt id="cirkuix.App.on_file_savedefaults">
  452. <tt class="descname">on_file_savedefaults</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_file_savedefaults" title="Permalink to this definition">¶</a></dt>
  453. <dd><p>Callback for menu item File-&gt;Save Defaults. Saves application default options
  454. (<tt class="docutils literal"><span class="pre">self.defaults</span></tt>) to defaults.json.</p>
  455. <table class="docutils field-list" frame="void" rules="none">
  456. <col class="field-name" />
  457. <col class="field-body" />
  458. <tbody valign="top">
  459. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignored.</td>
  460. </tr>
  461. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  462. </tr>
  463. </tbody>
  464. </table>
  465. </dd></dl>
  466. <dl class="method">
  467. <dt id="cirkuix.App.on_fileopenexcellon">
  468. <tt class="descname">on_fileopenexcellon</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_fileopenexcellon" title="Permalink to this definition">¶</a></dt>
  469. <dd><p>Callback for menu item File-&gt;Open Excellon. Defines a function that is then passed
  470. to <tt class="docutils literal"><span class="pre">self.file_chooser_action()</span></tt>. It requests the creation of a CirkuixExcellon object
  471. and updates the progress bar throughout the process.</p>
  472. <table class="docutils field-list" frame="void" rules="none">
  473. <col class="field-name" />
  474. <col class="field-body" />
  475. <tbody valign="top">
  476. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignore</td>
  477. </tr>
  478. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  479. </tr>
  480. </tbody>
  481. </table>
  482. </dd></dl>
  483. <dl class="method">
  484. <dt id="cirkuix.App.on_fileopengcode">
  485. <tt class="descname">on_fileopengcode</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_fileopengcode" title="Permalink to this definition">¶</a></dt>
  486. <dd><p>Callback for menu item File-&gt;Open G-Code. Defines a function that is then passed
  487. to <tt class="docutils literal"><span class="pre">self.file_chooser_action()</span></tt>. It requests the creation of a CirkuixCNCjob object
  488. and updates the progress bar throughout the process.</p>
  489. <table class="docutils field-list" frame="void" rules="none">
  490. <col class="field-name" />
  491. <col class="field-body" />
  492. <tbody valign="top">
  493. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignore</td>
  494. </tr>
  495. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  496. </tr>
  497. </tbody>
  498. </table>
  499. </dd></dl>
  500. <dl class="method">
  501. <dt id="cirkuix.App.on_fileopengerber">
  502. <tt class="descname">on_fileopengerber</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_fileopengerber" title="Permalink to this definition">¶</a></dt>
  503. <dd><p>Callback for menu item File-&gt;Open Gerber. Defines a function that is then passed
  504. to <tt class="docutils literal"><span class="pre">self.file_chooser_action()</span></tt>. It requests the creation of a CirkuixGerber object
  505. and updates the progress bar throughout the process.</p>
  506. <table class="docutils field-list" frame="void" rules="none">
  507. <col class="field-name" />
  508. <col class="field-body" />
  509. <tbody valign="top">
  510. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignore</td>
  511. </tr>
  512. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  513. </tr>
  514. </tbody>
  515. </table>
  516. </dd></dl>
  517. <dl class="method">
  518. <dt id="cirkuix.App.on_filequit">
  519. <tt class="descname">on_filequit</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_filequit" title="Permalink to this definition">¶</a></dt>
  520. <dd><p>Callback for menu item File-&gt;Quit. Closes the application.</p>
  521. <table class="docutils field-list" frame="void" rules="none">
  522. <col class="field-name" />
  523. <col class="field-body" />
  524. <tbody valign="top">
  525. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Whatever is passed by the event. Ignore.</td>
  526. </tr>
  527. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  528. </tr>
  529. </tbody>
  530. </table>
  531. </dd></dl>
  532. <dl class="method">
  533. <dt id="cirkuix.App.on_generate_cncjob">
  534. <tt class="descname">on_generate_cncjob</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_generate_cncjob" title="Permalink to this definition">¶</a></dt>
  535. <dd><p>Callback for button on geometry form to generate CNC job.</p>
  536. <table class="docutils field-list" frame="void" rules="none">
  537. <col class="field-name" />
  538. <col class="field-body" />
  539. <tbody valign="top">
  540. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  541. </tr>
  542. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  543. </tr>
  544. </tbody>
  545. </table>
  546. </dd></dl>
  547. <dl class="method">
  548. <dt id="cirkuix.App.on_generate_excellon_cncjob">
  549. <tt class="descname">on_generate_excellon_cncjob</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_generate_excellon_cncjob" title="Permalink to this definition">¶</a></dt>
  550. <dd><p>Callback for button active/click on Excellon form to
  551. create a CNC Job for the Excellon file.</p>
  552. <table class="docutils field-list" frame="void" rules="none">
  553. <col class="field-name" />
  554. <col class="field-body" />
  555. <tbody valign="top">
  556. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  557. </tr>
  558. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  559. </tr>
  560. </tbody>
  561. </table>
  562. </dd></dl>
  563. <dl class="method">
  564. <dt id="cirkuix.App.on_generate_gerber_bounding_box">
  565. <tt class="descname">on_generate_gerber_bounding_box</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_generate_gerber_bounding_box" title="Permalink to this definition">¶</a></dt>
  566. <dd><p>Callback for request from the Gerber form to generate a bounding box for the
  567. geometry in the object. Creates a CirkuixGeometry with the bounding box.</p>
  568. <table class="docutils field-list" frame="void" rules="none">
  569. <col class="field-name" />
  570. <col class="field-body" />
  571. <tbody valign="top">
  572. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; Ignored.</td>
  573. </tr>
  574. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  575. </tr>
  576. </tbody>
  577. </table>
  578. </dd></dl>
  579. <dl class="method">
  580. <dt id="cirkuix.App.on_generate_isolation">
  581. <tt class="descname">on_generate_isolation</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_generate_isolation" title="Permalink to this definition">¶</a></dt>
  582. <dd><p>Callback for button on Gerber form to create isolation routing geometry.</p>
  583. <table class="docutils field-list" frame="void" rules="none">
  584. <col class="field-name" />
  585. <col class="field-body" />
  586. <tbody valign="top">
  587. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  588. </tr>
  589. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  590. </tr>
  591. </tbody>
  592. </table>
  593. </dd></dl>
  594. <dl class="method">
  595. <dt id="cirkuix.App.on_generate_paintarea">
  596. <tt class="descname">on_generate_paintarea</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_generate_paintarea" title="Permalink to this definition">¶</a></dt>
  597. <dd><p>Callback for button on geometry form.
  598. Subscribes to the &#8220;Click on plot&#8221; event and continues
  599. after the click. Finds the polygon containing
  600. the clicked point and runs clear_poly() on it, resulting
  601. in a new CirkuixGeometry object.</p>
  602. <table class="docutils field-list" frame="void" rules="none">
  603. <col class="field-name" />
  604. <col class="field-body" />
  605. <tbody valign="top">
  606. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  607. </tr>
  608. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  609. </tr>
  610. </tbody>
  611. </table>
  612. </dd></dl>
  613. <dl class="method">
  614. <dt id="cirkuix.App.on_gerber_generate_cutout">
  615. <tt class="descname">on_gerber_generate_cutout</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_gerber_generate_cutout" title="Permalink to this definition">¶</a></dt>
  616. <dd><p>Callback for button on Gerber form to create geometry with lines
  617. for cutting off the board.</p>
  618. <table class="docutils field-list" frame="void" rules="none">
  619. <col class="field-name" />
  620. <col class="field-body" />
  621. <tbody valign="top">
  622. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  623. </tr>
  624. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  625. </tr>
  626. </tbody>
  627. </table>
  628. </dd></dl>
  629. <dl class="method">
  630. <dt id="cirkuix.App.on_gerber_generate_noncopper">
  631. <tt class="descname">on_gerber_generate_noncopper</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_gerber_generate_noncopper" title="Permalink to this definition">¶</a></dt>
  632. <dd><p>Callback for button on Gerber form to create a geometry object
  633. with polygons covering the area without copper or negative of the
  634. Gerber.</p>
  635. <table class="docutils field-list" frame="void" rules="none">
  636. <col class="field-name" />
  637. <col class="field-body" />
  638. <tbody valign="top">
  639. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  640. </tr>
  641. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  642. </tr>
  643. </tbody>
  644. </table>
  645. </dd></dl>
  646. <dl class="method">
  647. <dt id="cirkuix.App.on_key_over_plot">
  648. <tt class="descname">on_key_over_plot</tt><big>(</big><em>event</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_key_over_plot" title="Permalink to this definition">¶</a></dt>
  649. <dd><p>Callback for the key pressed event when the canvas is focused. Keyboard
  650. shortcuts are handled here. So far, these are the shortcuts:</p>
  651. <table border="1" class="docutils">
  652. <colgroup>
  653. <col width="19%" />
  654. <col width="81%" />
  655. </colgroup>
  656. <thead valign="bottom">
  657. <tr class="row-odd"><th class="head">Key</th>
  658. <th class="head">Action</th>
  659. </tr>
  660. </thead>
  661. <tbody valign="top">
  662. <tr class="row-even"><td>&#8216;1&#8217;</td>
  663. <td>Zoom-fit. Fits the axes limits to the data.</td>
  664. </tr>
  665. <tr class="row-odd"><td>&#8216;2&#8217;</td>
  666. <td>Zoom-out.</td>
  667. </tr>
  668. <tr class="row-even"><td>&#8216;3&#8217;</td>
  669. <td>Zoom-in.</td>
  670. </tr>
  671. </tbody>
  672. </table>
  673. <table class="docutils field-list" frame="void" rules="none">
  674. <col class="field-name" />
  675. <col class="field-body" />
  676. <tbody valign="top">
  677. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>event</strong> &#8211; Ignored.</td>
  678. </tr>
  679. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  680. </tr>
  681. </tbody>
  682. </table>
  683. </dd></dl>
  684. <dl class="method">
  685. <dt id="cirkuix.App.on_mouse_move_over_plot">
  686. <tt class="descname">on_mouse_move_over_plot</tt><big>(</big><em>event</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_mouse_move_over_plot" title="Permalink to this definition">¶</a></dt>
  687. <dd><p>Callback for the mouse motion event over the plot. This event is generated
  688. by the Matplotlib backend and has been registered in <tt class="docutils literal"><span class="pre">self.__init__()</span></tt>.
  689. For details, see: <a class="reference external" href="http://matplotlib.org/users/event_handling.html">http://matplotlib.org/users/event_handling.html</a></p>
  690. <table class="docutils field-list" frame="void" rules="none">
  691. <col class="field-name" />
  692. <col class="field-body" />
  693. <tbody valign="top">
  694. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>event</strong> &#8211; Contains information about the event.</td>
  695. </tr>
  696. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  697. </tr>
  698. </tbody>
  699. </table>
  700. </dd></dl>
  701. <dl class="method">
  702. <dt id="cirkuix.App.on_options_app2object">
  703. <tt class="descname">on_options_app2object</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_options_app2object" title="Permalink to this definition">¶</a></dt>
  704. <dd><p>Callback for Options-&gt;Transfer Options-&gt;App=&gt;Object. Copies options
  705. from application defaults to the currently selected object.</p>
  706. <table class="docutils field-list" frame="void" rules="none">
  707. <col class="field-name" />
  708. <col class="field-body" />
  709. <tbody valign="top">
  710. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignored.</td>
  711. </tr>
  712. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  713. </tr>
  714. </tbody>
  715. </table>
  716. </dd></dl>
  717. <dl class="method">
  718. <dt id="cirkuix.App.on_options_app2project">
  719. <tt class="descname">on_options_app2project</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_options_app2project" title="Permalink to this definition">¶</a></dt>
  720. <dd><p>Callback for Options-&gt;Transfer Options-&gt;App=&gt;Project. Copies options
  721. from application defaults to project defaults.</p>
  722. <table class="docutils field-list" frame="void" rules="none">
  723. <col class="field-name" />
  724. <col class="field-body" />
  725. <tbody valign="top">
  726. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignored.</td>
  727. </tr>
  728. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  729. </tr>
  730. </tbody>
  731. </table>
  732. </dd></dl>
  733. <dl class="method">
  734. <dt id="cirkuix.App.on_options_combo_change">
  735. <tt class="descname">on_options_combo_change</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_options_combo_change" title="Permalink to this definition">¶</a></dt>
  736. <dd><p>Called when the combo box to choose between application defaults and
  737. project option changes value. The corresponding variables are
  738. copied to the UI.</p>
  739. <table class="docutils field-list" frame="void" rules="none">
  740. <col class="field-name" />
  741. <col class="field-body" />
  742. <tbody valign="top">
  743. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called. Ignore.</td>
  744. </tr>
  745. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  746. </tr>
  747. </tbody>
  748. </table>
  749. </dd></dl>
  750. <dl class="method">
  751. <dt id="cirkuix.App.on_options_object2app">
  752. <tt class="descname">on_options_object2app</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_options_object2app" title="Permalink to this definition">¶</a></dt>
  753. <dd><p>Callback for Options-&gt;Transfer Options-&gt;Object=&gt;App. Copies options
  754. from the currently selected object to application defaults.</p>
  755. <table class="docutils field-list" frame="void" rules="none">
  756. <col class="field-name" />
  757. <col class="field-body" />
  758. <tbody valign="top">
  759. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignored.</td>
  760. </tr>
  761. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  762. </tr>
  763. </tbody>
  764. </table>
  765. </dd></dl>
  766. <dl class="method">
  767. <dt id="cirkuix.App.on_options_object2project">
  768. <tt class="descname">on_options_object2project</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_options_object2project" title="Permalink to this definition">¶</a></dt>
  769. <dd><p>Callback for Options-&gt;Transfer Options-&gt;Object=&gt;Project. Copies options
  770. from the currently selected object to project defaults.</p>
  771. <table class="docutils field-list" frame="void" rules="none">
  772. <col class="field-name" />
  773. <col class="field-body" />
  774. <tbody valign="top">
  775. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignored.</td>
  776. </tr>
  777. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  778. </tr>
  779. </tbody>
  780. </table>
  781. </dd></dl>
  782. <dl class="method">
  783. <dt id="cirkuix.App.on_options_project2app">
  784. <tt class="descname">on_options_project2app</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_options_project2app" title="Permalink to this definition">¶</a></dt>
  785. <dd><p>Callback for Options-&gt;Transfer Options-&gt;Project=&gt;App. Copies options
  786. from project defaults to application defaults.</p>
  787. <table class="docutils field-list" frame="void" rules="none">
  788. <col class="field-name" />
  789. <col class="field-body" />
  790. <tbody valign="top">
  791. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignored.</td>
  792. </tr>
  793. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  794. </tr>
  795. </tbody>
  796. </table>
  797. </dd></dl>
  798. <dl class="method">
  799. <dt id="cirkuix.App.on_options_project2object">
  800. <tt class="descname">on_options_project2object</tt><big>(</big><em>param</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_options_project2object" title="Permalink to this definition">¶</a></dt>
  801. <dd><p>Callback for Options-&gt;Transfer Options-&gt;Project=&gt;Object. Copies options
  802. from project defaults to the currently selected object.</p>
  803. <table class="docutils field-list" frame="void" rules="none">
  804. <col class="field-name" />
  805. <col class="field-body" />
  806. <tbody valign="top">
  807. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>param</strong> &#8211; Ignored.</td>
  808. </tr>
  809. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  810. </tr>
  811. </tbody>
  812. </table>
  813. </dd></dl>
  814. <dl class="method">
  815. <dt id="cirkuix.App.on_options_update">
  816. <tt class="descname">on_options_update</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_options_update" title="Permalink to this definition">¶</a></dt>
  817. <dd><p>Called whenever a value in the options/defaults form changes.
  818. All values are updated. Can be inhibited by setting <tt class="docutils literal"><span class="pre">self.options_update_ignore</span> <span class="pre">=</span> <span class="pre">True</span></tt>,
  819. which may be necessary when updating the UI from code and not by the user.</p>
  820. <table class="docutils field-list" frame="void" rules="none">
  821. <col class="field-name" />
  822. <col class="field-body" />
  823. <tbody valign="top">
  824. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called. Ignore.</td>
  825. </tr>
  826. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  827. </tr>
  828. </tbody>
  829. </table>
  830. </dd></dl>
  831. <dl class="method">
  832. <dt id="cirkuix.App.on_replot">
  833. <tt class="descname">on_replot</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_replot" title="Permalink to this definition">¶</a></dt>
  834. <dd><p>Callback for toolbar button. Re-plots all objects.</p>
  835. <table class="docutils field-list" frame="void" rules="none">
  836. <col class="field-name" />
  837. <col class="field-body" />
  838. <tbody valign="top">
  839. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  840. </tr>
  841. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  842. </tr>
  843. </tbody>
  844. </table>
  845. </dd></dl>
  846. <dl class="method">
  847. <dt id="cirkuix.App.on_row_activated">
  848. <tt class="descname">on_row_activated</tt><big>(</big><em>widget</em>, <em>path</em>, <em>col</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_row_activated" title="Permalink to this definition">¶</a></dt>
  849. <dd><p>Callback for selection activation (Enter or double-click) on the Project list.
  850. Switches the notebook page to the object properties form. Calls
  851. <tt class="docutils literal"><span class="pre">self.notebook.set_current_page(1)</span></tt>.</p>
  852. <table class="docutils field-list" frame="void" rules="none">
  853. <col class="field-name" />
  854. <col class="field-body" />
  855. <tbody valign="top">
  856. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  857. <li><strong>widget</strong> &#8211; Ignored.</li>
  858. <li><strong>path</strong> &#8211; Ignored.</li>
  859. <li><strong>col</strong> &#8211; Ignored.</li>
  860. </ul>
  861. </td>
  862. </tr>
  863. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">None</p>
  864. </td>
  865. </tr>
  866. </tbody>
  867. </table>
  868. </dd></dl>
  869. <dl class="method">
  870. <dt id="cirkuix.App.on_scale_object">
  871. <tt class="descname">on_scale_object</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_scale_object" title="Permalink to this definition">¶</a></dt>
  872. <dd><p>Callback for request to change an objects geometry scale. The object
  873. is re-scaled and replotted.</p>
  874. <table class="docutils field-list" frame="void" rules="none">
  875. <col class="field-name" />
  876. <col class="field-body" />
  877. <tbody valign="top">
  878. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; Ignored.</td>
  879. </tr>
  880. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  881. </tr>
  882. </tbody>
  883. </table>
  884. </dd></dl>
  885. <dl class="method">
  886. <dt id="cirkuix.App.on_tree_selection_changed">
  887. <tt class="descname">on_tree_selection_changed</tt><big>(</big><em>selection</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_tree_selection_changed" title="Permalink to this definition">¶</a></dt>
  888. <dd><p>Callback for selection change in the project list. This changes
  889. the currently selected CirkuixObj.</p>
  890. <table class="docutils field-list" frame="void" rules="none">
  891. <col class="field-name" />
  892. <col class="field-body" />
  893. <tbody valign="top">
  894. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>selection</strong> (<em>Gtk.TreeSelection</em>) &#8211; Selection associated to the project tree or list</td>
  895. </tr>
  896. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  897. </tr>
  898. </tbody>
  899. </table>
  900. </dd></dl>
  901. <dl class="method">
  902. <dt id="cirkuix.App.on_update_plot">
  903. <tt class="descname">on_update_plot</tt><big>(</big><em>widget</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_update_plot" title="Permalink to this definition">¶</a></dt>
  904. <dd><p>Callback for button on form for all kinds of objects.
  905. Re-plots the current object only.</p>
  906. <table class="docutils field-list" frame="void" rules="none">
  907. <col class="field-name" />
  908. <col class="field-body" />
  909. <tbody valign="top">
  910. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>widget</strong> &#8211; The widget from which this was called.</td>
  911. </tr>
  912. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  913. </tr>
  914. </tbody>
  915. </table>
  916. </dd></dl>
  917. <dl class="method">
  918. <dt id="cirkuix.App.on_zoom_fit">
  919. <tt class="descname">on_zoom_fit</tt><big>(</big><em>event</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_zoom_fit" title="Permalink to this definition">¶</a></dt>
  920. <dd><p>Callback for zoom-out request. This can be either from the corresponding
  921. toolbar button or the &#8216;1&#8217; key when the canvas is focused. Calls <tt class="docutils literal"><span class="pre">self.adjust_axes()</span></tt>
  922. with axes limits from the geometry bounds of all objects.</p>
  923. <table class="docutils field-list" frame="void" rules="none">
  924. <col class="field-name" />
  925. <col class="field-body" />
  926. <tbody valign="top">
  927. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>event</strong> &#8211; Ignored.</td>
  928. </tr>
  929. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  930. </tr>
  931. </tbody>
  932. </table>
  933. </dd></dl>
  934. <dl class="method">
  935. <dt id="cirkuix.App.on_zoom_in">
  936. <tt class="descname">on_zoom_in</tt><big>(</big><em>event</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_zoom_in" title="Permalink to this definition">¶</a></dt>
  937. <dd><p>Callback for zoom-in request. This can be either from the corresponding
  938. toolbar button or the &#8216;3&#8217; key when the canvas is focused. Calls <tt class="docutils literal"><span class="pre">self.zoom()</span></tt>.</p>
  939. <table class="docutils field-list" frame="void" rules="none">
  940. <col class="field-name" />
  941. <col class="field-body" />
  942. <tbody valign="top">
  943. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>event</strong> &#8211; Ignored.</td>
  944. </tr>
  945. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  946. </tr>
  947. </tbody>
  948. </table>
  949. </dd></dl>
  950. <dl class="method">
  951. <dt id="cirkuix.App.on_zoom_out">
  952. <tt class="descname">on_zoom_out</tt><big>(</big><em>event</em><big>)</big><a class="headerlink" href="#cirkuix.App.on_zoom_out" title="Permalink to this definition">¶</a></dt>
  953. <dd><p>Callback for zoom-out request. This can be either from the corresponding
  954. toolbar button or the &#8216;2&#8217; key when the canvas is focused. Calls <tt class="docutils literal"><span class="pre">self.zoom()</span></tt>.</p>
  955. <table class="docutils field-list" frame="void" rules="none">
  956. <col class="field-name" />
  957. <col class="field-body" />
  958. <tbody valign="top">
  959. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>event</strong> &#8211; Ignored.</td>
  960. </tr>
  961. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  962. </tr>
  963. </tbody>
  964. </table>
  965. </dd></dl>
  966. <dl class="method">
  967. <dt id="cirkuix.App.options2form">
  968. <tt class="descname">options2form</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.options2form" title="Permalink to this definition">¶</a></dt>
  969. <dd><p>Sets the &#8216;Project Options&#8217; or &#8216;Application Defaults&#8217; form with values from
  970. <tt class="docutils literal"><span class="pre">self.options``or</span> <span class="pre">``self.defaults</span></tt>.
  971. :return : None
  972. :rtype : None</p>
  973. </dd></dl>
  974. <dl class="method">
  975. <dt id="cirkuix.App.plot_all">
  976. <tt class="descname">plot_all</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.plot_all" title="Permalink to this definition">¶</a></dt>
  977. <dd><p>Re-generates all plots from all objects.</p>
  978. <table class="docutils field-list" frame="void" rules="none">
  979. <col class="field-name" />
  980. <col class="field-body" />
  981. <tbody valign="top">
  982. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  983. </tr>
  984. </tbody>
  985. </table>
  986. </dd></dl>
  987. <dl class="method">
  988. <dt id="cirkuix.App.read_form">
  989. <tt class="descname">read_form</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.read_form" title="Permalink to this definition">¶</a></dt>
  990. <dd><p>Reads the options form into self.defaults/self.options.</p>
  991. <table class="docutils field-list" frame="void" rules="none">
  992. <col class="field-name" />
  993. <col class="field-body" />
  994. <tbody valign="top">
  995. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  996. </tr>
  997. <tr class="field-even field"><th class="field-name">Return type:</th><td class="field-body">None</td>
  998. </tr>
  999. </tbody>
  1000. </table>
  1001. </dd></dl>
  1002. <dl class="method">
  1003. <dt id="cirkuix.App.read_form_item">
  1004. <tt class="descname">read_form_item</tt><big>(</big><em>name</em>, <em>dest</em><big>)</big><a class="headerlink" href="#cirkuix.App.read_form_item" title="Permalink to this definition">¶</a></dt>
  1005. <dd><p>Reads the value of a form item in the defaults/options form and
  1006. saves it to the corresponding dictionary.</p>
  1007. <table class="docutils field-list" frame="void" rules="none">
  1008. <col class="field-name" />
  1009. <col class="field-body" />
  1010. <tbody valign="top">
  1011. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  1012. <li><strong>name</strong> (<em>str</em>) &#8211; Name of the form item. A key in <tt class="docutils literal"><span class="pre">self.defaults</span></tt> or
  1013. <tt class="docutils literal"><span class="pre">self.options</span></tt>.</li>
  1014. <li><strong>dest</strong> (<em>dict</em>) &#8211; Dictionary to which to save the value.</li>
  1015. </ul>
  1016. </td>
  1017. </tr>
  1018. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">None</p>
  1019. </td>
  1020. </tr>
  1021. </tbody>
  1022. </table>
  1023. </dd></dl>
  1024. <dl class="method">
  1025. <dt id="cirkuix.App.set_form_item">
  1026. <tt class="descname">set_form_item</tt><big>(</big><em>name</em>, <em>value</em><big>)</big><a class="headerlink" href="#cirkuix.App.set_form_item" title="Permalink to this definition">¶</a></dt>
  1027. <dd><p>Sets a form item &#8216;name&#8217; in the GUI with the given &#8216;value&#8217;. The syntax of
  1028. form names in the GUI is &lt;kind&gt;_app_&lt;name&gt;, where kind is one of: rb (radio button),
  1029. cb (check button), entry_eval or entry_text (entry), combo (combo box). name is
  1030. whatever name it&#8217;s been given. For self.defaults, name is a key in the dictionary.</p>
  1031. <table class="docutils field-list" frame="void" rules="none">
  1032. <col class="field-name" />
  1033. <col class="field-body" />
  1034. <tbody valign="top">
  1035. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  1036. <li><strong>name</strong> (<em>str</em>) &#8211; Name of the form field.</li>
  1037. <li><strong>value</strong> (<em>Depends on field kind.</em>) &#8211; The value to set the form field to.</li>
  1038. </ul>
  1039. </td>
  1040. </tr>
  1041. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">None</p>
  1042. </td>
  1043. </tr>
  1044. </tbody>
  1045. </table>
  1046. </dd></dl>
  1047. <dl class="method">
  1048. <dt id="cirkuix.App.set_list_selection">
  1049. <tt class="descname">set_list_selection</tt><big>(</big><em>name</em><big>)</big><a class="headerlink" href="#cirkuix.App.set_list_selection" title="Permalink to this definition">¶</a></dt>
  1050. <dd><p>Marks a given object as selected in the list ob objects
  1051. in the GUI. This selection will in turn trigger
  1052. <tt class="docutils literal"><span class="pre">self.on_tree_selection_changed()</span></tt>.</p>
  1053. <table class="docutils field-list" frame="void" rules="none">
  1054. <col class="field-name" />
  1055. <col class="field-body" />
  1056. <tbody valign="top">
  1057. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>name</strong> (<em>str</em>) &#8211; Name of the object.</td>
  1058. </tr>
  1059. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  1060. </tr>
  1061. </tbody>
  1062. </table>
  1063. </dd></dl>
  1064. <dl class="method">
  1065. <dt id="cirkuix.App.set_progress_bar">
  1066. <tt class="descname">set_progress_bar</tt><big>(</big><em>percentage</em>, <em>text=''</em><big>)</big><a class="headerlink" href="#cirkuix.App.set_progress_bar" title="Permalink to this definition">¶</a></dt>
  1067. <dd><p>Sets the application&#8217;s progress bar to a given fraction and text.</p>
  1068. <table class="docutils field-list" frame="void" rules="none">
  1069. <col class="field-name" />
  1070. <col class="field-body" />
  1071. <tbody valign="top">
  1072. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  1073. <li><strong>percentage</strong> (<em>float</em>) &#8211; The fraction (0.0-1.0) of the progress.</li>
  1074. <li><strong>text</strong> (<em>str</em>) &#8211; Text to display on the progress bar.</li>
  1075. </ul>
  1076. </td>
  1077. </tr>
  1078. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last"></p>
  1079. </td>
  1080. </tr>
  1081. </tbody>
  1082. </table>
  1083. </dd></dl>
  1084. <dl class="method">
  1085. <dt id="cirkuix.App.setup_component_editor">
  1086. <tt class="descname">setup_component_editor</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.setup_component_editor" title="Permalink to this definition">¶</a></dt>
  1087. <dd><p>Initial configuration of the component editor. Creates
  1088. a page titled &#8220;Selection&#8221; on the notebook on the left
  1089. side of the main window.</p>
  1090. <table class="docutils field-list" frame="void" rules="none">
  1091. <col class="field-name" />
  1092. <col class="field-body" />
  1093. <tbody valign="top">
  1094. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  1095. </tr>
  1096. </tbody>
  1097. </table>
  1098. </dd></dl>
  1099. <dl class="method">
  1100. <dt id="cirkuix.App.setup_obj_classes">
  1101. <tt class="descname">setup_obj_classes</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.setup_obj_classes" title="Permalink to this definition">¶</a></dt>
  1102. <dd><p>Sets up application specifics on the CirkuixObj class.</p>
  1103. <table class="docutils field-list" frame="void" rules="none">
  1104. <col class="field-name" />
  1105. <col class="field-body" />
  1106. <tbody valign="top">
  1107. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  1108. </tr>
  1109. </tbody>
  1110. </table>
  1111. </dd></dl>
  1112. <dl class="method">
  1113. <dt id="cirkuix.App.setup_plot">
  1114. <tt class="descname">setup_plot</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.setup_plot" title="Permalink to this definition">¶</a></dt>
  1115. <dd><p>Sets up the main plotting area by creating a Matplotlib
  1116. figure in self.canvas, adding axes and configuring them.
  1117. These axes should not be ploted on and are just there to
  1118. display the axes ticks and grid.</p>
  1119. <table class="docutils field-list" frame="void" rules="none">
  1120. <col class="field-name" />
  1121. <col class="field-body" />
  1122. <tbody valign="top">
  1123. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  1124. </tr>
  1125. <tr class="field-even field"><th class="field-name">Return type:</th><td class="field-body">None</td>
  1126. </tr>
  1127. </tbody>
  1128. </table>
  1129. </dd></dl>
  1130. <dl class="method">
  1131. <dt id="cirkuix.App.setup_project_list">
  1132. <tt class="descname">setup_project_list</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.App.setup_project_list" title="Permalink to this definition">¶</a></dt>
  1133. <dd><p>Sets up list or Tree where whatever has been loaded or created is
  1134. displayed.</p>
  1135. <table class="docutils field-list" frame="void" rules="none">
  1136. <col class="field-name" />
  1137. <col class="field-body" />
  1138. <tbody valign="top">
  1139. <tr class="field-odd field"><th class="field-name">Returns:</th><td class="field-body">None</td>
  1140. </tr>
  1141. </tbody>
  1142. </table>
  1143. </dd></dl>
  1144. <dl class="method">
  1145. <dt id="cirkuix.App.zoom">
  1146. <tt class="descname">zoom</tt><big>(</big><em>factor</em>, <em>center=None</em><big>)</big><a class="headerlink" href="#cirkuix.App.zoom" title="Permalink to this definition">¶</a></dt>
  1147. <dd><p>Zooms the plot by factor around a given
  1148. center point. Takes care of re-drawing.</p>
  1149. <table class="docutils field-list" frame="void" rules="none">
  1150. <col class="field-name" />
  1151. <col class="field-body" />
  1152. <tbody valign="top">
  1153. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
  1154. <li><strong>factor</strong> (<em>float</em>) &#8211; Number by which to scale the plot.</li>
  1155. <li><strong>center</strong> (<em>list</em>) &#8211; Coordinates [x, y] of the point around which to scale the plot.</li>
  1156. </ul>
  1157. </td>
  1158. </tr>
  1159. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">None</p>
  1160. </td>
  1161. </tr>
  1162. </tbody>
  1163. </table>
  1164. </dd></dl>
  1165. </dd></dl>
  1166. <dl class="class">
  1167. <dt id="cirkuix.Geometry">
  1168. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">Geometry</tt><a class="headerlink" href="#cirkuix.Geometry" title="Permalink to this definition">¶</a></dt>
  1169. <dd><dl class="method">
  1170. <dt id="cirkuix.Geometry.bounds">
  1171. <tt class="descname">bounds</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.Geometry.bounds" title="Permalink to this definition">¶</a></dt>
  1172. <dd><p>Returns coordinates of rectangular bounds
  1173. of geometry: (xmin, ymin, xmax, ymax).</p>
  1174. </dd></dl>
  1175. <dl class="method">
  1176. <dt id="cirkuix.Geometry.clear_polygon">
  1177. <tt class="descname">clear_polygon</tt><big>(</big><em>polygon</em>, <em>tooldia</em>, <em>overlap=0.15</em><big>)</big><a class="headerlink" href="#cirkuix.Geometry.clear_polygon" title="Permalink to this definition">¶</a></dt>
  1178. <dd><p>Creates geometry inside a polygon for a tool to cover
  1179. the whole area.</p>
  1180. </dd></dl>
  1181. <dl class="method">
  1182. <dt id="cirkuix.Geometry.convert_units">
  1183. <tt class="descname">convert_units</tt><big>(</big><em>units</em><big>)</big><a class="headerlink" href="#cirkuix.Geometry.convert_units" title="Permalink to this definition">¶</a></dt>
  1184. <dd><p>Converts the units of the object to <tt class="docutils literal"><span class="pre">units</span></tt> by scaling all
  1185. the geometry appropriately.</p>
  1186. <table class="docutils field-list" frame="void" rules="none">
  1187. <col class="field-name" />
  1188. <col class="field-body" />
  1189. <tbody valign="top">
  1190. <tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>units</strong> (<em>str</em>) &#8211; &#8220;IN&#8221; or &#8220;MM&#8221;</td>
  1191. </tr>
  1192. <tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">Scaling factor resulting from unit change.</td>
  1193. </tr>
  1194. <tr class="field-odd field"><th class="field-name">Return type:</th><td class="field-body">float</td>
  1195. </tr>
  1196. </tbody>
  1197. </table>
  1198. </dd></dl>
  1199. <dl class="method">
  1200. <dt id="cirkuix.Geometry.get_empty_area">
  1201. <tt class="descname">get_empty_area</tt><big>(</big><em>boundary=None</em><big>)</big><a class="headerlink" href="#cirkuix.Geometry.get_empty_area" title="Permalink to this definition">¶</a></dt>
  1202. <dd><p>Returns the complement of self.solid_geometry within
  1203. the given boundary polygon. If not specified, it defaults to
  1204. the rectangular bounding box of self.solid_geometry.</p>
  1205. </dd></dl>
  1206. <dl class="method">
  1207. <dt id="cirkuix.Geometry.isolation_geometry">
  1208. <tt class="descname">isolation_geometry</tt><big>(</big><em>offset</em><big>)</big><a class="headerlink" href="#cirkuix.Geometry.isolation_geometry" title="Permalink to this definition">¶</a></dt>
  1209. <dd><p>Creates contours around geometry at a given
  1210. offset distance.</p>
  1211. </dd></dl>
  1212. <dl class="method">
  1213. <dt id="cirkuix.Geometry.scale">
  1214. <tt class="descname">scale</tt><big>(</big><em>factor</em><big>)</big><a class="headerlink" href="#cirkuix.Geometry.scale" title="Permalink to this definition">¶</a></dt>
  1215. <dd><p>Scales all of the object&#8217;s geometry by a given factor. Override
  1216. this method.
  1217. :param factor: Number by which to scale.
  1218. :type factor: float
  1219. :return: None
  1220. :rtype: None</p>
  1221. </dd></dl>
  1222. <dl class="method">
  1223. <dt id="cirkuix.Geometry.size">
  1224. <tt class="descname">size</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.Geometry.size" title="Permalink to this definition">¶</a></dt>
  1225. <dd><p>Returns (width, height) of rectangular
  1226. bounds of geometry.</p>
  1227. </dd></dl>
  1228. </dd></dl>
  1229. <dl class="class">
  1230. <dt id="cirkuix.Gerber">
  1231. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">Gerber</tt><big>(</big><em>Geometry</em><big>)</big><a class="headerlink" href="#cirkuix.Gerber" title="Permalink to this definition">¶</a></dt>
  1232. <dd><p><strong>ATTRIBUTES</strong></p>
  1233. <ul class="simple">
  1234. <li><tt class="docutils literal"><span class="pre">apertures</span></tt> (dict): The keys are names/identifiers of each aperture.
  1235. The values are dictionaries key/value pairs which describe the aperture. The
  1236. type key is always present and the rest depend on the key:</li>
  1237. </ul>
  1238. <table border="1" class="docutils">
  1239. <colgroup>
  1240. <col width="24%" />
  1241. <col width="76%" />
  1242. </colgroup>
  1243. <thead valign="bottom">
  1244. <tr class="row-odd"><th class="head">Key</th>
  1245. <th class="head">Value</th>
  1246. </tr>
  1247. </thead>
  1248. <tbody valign="top">
  1249. <tr class="row-even"><td>type</td>
  1250. <td>(str) &#8220;C&#8221;, &#8220;R&#8221;, or &#8220;O&#8221;</td>
  1251. </tr>
  1252. <tr class="row-odd"><td>others</td>
  1253. <td>Depend on <tt class="docutils literal"><span class="pre">type</span></tt></td>
  1254. </tr>
  1255. </tbody>
  1256. </table>
  1257. <ul class="simple">
  1258. <li><tt class="docutils literal"><span class="pre">paths</span></tt> (list): A path is described by a line an aperture that follows that
  1259. line. Each paths[i] is a dictionary:</li>
  1260. </ul>
  1261. <table border="1" class="docutils">
  1262. <colgroup>
  1263. <col width="20%" />
  1264. <col width="80%" />
  1265. </colgroup>
  1266. <thead valign="bottom">
  1267. <tr class="row-odd"><th class="head">Key</th>
  1268. <th class="head">Value</th>
  1269. </tr>
  1270. </thead>
  1271. <tbody valign="top">
  1272. <tr class="row-even"><td>linestring</td>
  1273. <td>(Shapely.LineString) The actual path.</td>
  1274. </tr>
  1275. <tr class="row-odd"><td>aperture</td>
  1276. <td>(str) The key for an aperture in apertures.</td>
  1277. </tr>
  1278. </tbody>
  1279. </table>
  1280. <ul class="simple">
  1281. <li><tt class="docutils literal"><span class="pre">flashes</span></tt> (list): Flashes are single-point strokes of an aperture. Each
  1282. is a dictionary:</li>
  1283. </ul>
  1284. <table border="1" class="docutils">
  1285. <colgroup>
  1286. <col width="20%" />
  1287. <col width="80%" />
  1288. </colgroup>
  1289. <thead valign="bottom">
  1290. <tr class="row-odd"><th class="head">Key</th>
  1291. <th class="head">Value</th>
  1292. </tr>
  1293. </thead>
  1294. <tbody valign="top">
  1295. <tr class="row-even"><td>loc</td>
  1296. <td>(list) [x (float), y (float)] coordinates.</td>
  1297. </tr>
  1298. <tr class="row-odd"><td>aperture</td>
  1299. <td>(str) The key for an aperture in apertures.</td>
  1300. </tr>
  1301. </tbody>
  1302. </table>
  1303. <ul class="simple">
  1304. <li><tt class="docutils literal"><span class="pre">regions</span></tt> (list): Are surfaces defined by a polygon (Shapely.Polygon),
  1305. which have an exterior and zero or more interiors. An aperture is also
  1306. associated with a region. Each is a dictionary:</li>
  1307. </ul>
  1308. <table border="1" class="docutils">
  1309. <colgroup>
  1310. <col width="18%" />
  1311. <col width="82%" />
  1312. </colgroup>
  1313. <thead valign="bottom">
  1314. <tr class="row-odd"><th class="head">Key</th>
  1315. <th class="head">Value</th>
  1316. </tr>
  1317. </thead>
  1318. <tbody valign="top">
  1319. <tr class="row-even"><td>polygon</td>
  1320. <td>(Shapely.Polygon) The polygon defining the region.</td>
  1321. </tr>
  1322. <tr class="row-odd"><td>aperture</td>
  1323. <td>(str) The key for an aperture in apertures.</td>
  1324. </tr>
  1325. </tbody>
  1326. </table>
  1327. <ul class="simple">
  1328. <li><tt class="docutils literal"><span class="pre">flash_geometry</span></tt> (list): List of (Shapely) geometric object resulting
  1329. from <tt class="docutils literal"><span class="pre">flashes</span></tt>. These are generated from <tt class="docutils literal"><span class="pre">flashes</span></tt> in <tt class="docutils literal"><span class="pre">do_flashes()</span></tt>.</li>
  1330. <li><tt class="docutils literal"><span class="pre">buffered_paths</span></tt> (list): List of (Shapely) polygons resulting from
  1331. <em>buffering</em> (or thickening) the <tt class="docutils literal"><span class="pre">paths</span></tt> with the aperture. These are
  1332. generated from <tt class="docutils literal"><span class="pre">paths</span></tt> in <tt class="docutils literal"><span class="pre">buffer_paths()</span></tt>.</li>
  1333. </ul>
  1334. <dl class="method">
  1335. <dt id="cirkuix.Gerber.aperture_parse">
  1336. <tt class="descname">aperture_parse</tt><big>(</big><em>gline</em><big>)</big><a class="headerlink" href="#cirkuix.Gerber.aperture_parse" title="Permalink to this definition">¶</a></dt>
  1337. <dd><p>Parse gerber aperture definition into dictionary of apertures.
  1338. The following kinds and their attributes are supported:</p>
  1339. <ul class="simple">
  1340. <li><em>Circular (C)</em>: size (float)</li>
  1341. <li><em>Rectangle (R)</em>: width (float), height (float)</li>
  1342. <li><em>Obround (O)</em>: width (float), height (float). NOTE: This can
  1343. be parsed, but it is not supported further yet.</li>
  1344. </ul>
  1345. </dd></dl>
  1346. <dl class="method">
  1347. <dt id="cirkuix.Gerber.create_geometry">
  1348. <tt class="descname">create_geometry</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.Gerber.create_geometry" title="Permalink to this definition">¶</a></dt>
  1349. <dd><p>Geometry from a Gerber file is made up entirely of polygons.
  1350. Every stroke (linear or circular) has an aperture which gives
  1351. it thickness. Additionally, aperture strokes have non-zero area,
  1352. and regions naturally do as well.
  1353. :rtype : None
  1354. &#64;return: None</p>
  1355. </dd></dl>
  1356. <dl class="attribute">
  1357. <dt id="cirkuix.Gerber.digits">
  1358. <tt class="descname">digits</tt><em class="property"> = None</em><a class="headerlink" href="#cirkuix.Gerber.digits" title="Permalink to this definition">¶</a></dt>
  1359. <dd><p>Number of integer digits in Gerber numbers. Used during parsing.</p>
  1360. </dd></dl>
  1361. <dl class="method">
  1362. <dt id="cirkuix.Gerber.do_flashes">
  1363. <tt class="descname">do_flashes</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.Gerber.do_flashes" title="Permalink to this definition">¶</a></dt>
  1364. <dd><p>Creates geometry for Gerber flashes (aperture on a single point).</p>
  1365. </dd></dl>
  1366. <dl class="method">
  1367. <dt id="cirkuix.Gerber.fix_regions">
  1368. <tt class="descname">fix_regions</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.Gerber.fix_regions" title="Permalink to this definition">¶</a></dt>
  1369. <dd><p>Overwrites the region polygons with fixed
  1370. versions if found to be invalid (according to Shapely).</p>
  1371. </dd></dl>
  1372. <dl class="attribute">
  1373. <dt id="cirkuix.Gerber.fraction">
  1374. <tt class="descname">fraction</tt><em class="property"> = None</em><a class="headerlink" href="#cirkuix.Gerber.fraction" title="Permalink to this definition">¶</a></dt>
  1375. <dd><p>Number of fraction digits in Gerber numbers. Used during parsing.</p>
  1376. </dd></dl>
  1377. <dl class="method">
  1378. <dt id="cirkuix.Gerber.parse_file">
  1379. <tt class="descname">parse_file</tt><big>(</big><em>filename</em><big>)</big><a class="headerlink" href="#cirkuix.Gerber.parse_file" title="Permalink to this definition">¶</a></dt>
  1380. <dd><p>Calls Gerber.parse_lines() with array of lines
  1381. read from the given file.</p>
  1382. </dd></dl>
  1383. <dl class="method">
  1384. <dt id="cirkuix.Gerber.parse_lines">
  1385. <tt class="descname">parse_lines</tt><big>(</big><em>glines</em><big>)</big><a class="headerlink" href="#cirkuix.Gerber.parse_lines" title="Permalink to this definition">¶</a></dt>
  1386. <dd><p>Main Gerber parser.</p>
  1387. </dd></dl>
  1388. <dl class="method">
  1389. <dt id="cirkuix.Gerber.scale">
  1390. <tt class="descname">scale</tt><big>(</big><em>factor</em><big>)</big><a class="headerlink" href="#cirkuix.Gerber.scale" title="Permalink to this definition">¶</a></dt>
  1391. <dd><p>Scales the objects&#8217; geometry on the XY plane by a given factor.
  1392. These are:</p>
  1393. <ul class="simple">
  1394. <li><tt class="docutils literal"><span class="pre">apertures</span></tt></li>
  1395. <li><tt class="docutils literal"><span class="pre">paths</span></tt></li>
  1396. <li><tt class="docutils literal"><span class="pre">regions</span></tt></li>
  1397. <li><tt class="docutils literal"><span class="pre">flashes</span></tt></li>
  1398. </ul>
  1399. <p>Then <tt class="docutils literal"><span class="pre">buffered_paths</span></tt>, <tt class="docutils literal"><span class="pre">flash_geometry</span></tt> and <tt class="docutils literal"><span class="pre">solid_geometry</span></tt>
  1400. are re-created with <tt class="docutils literal"><span class="pre">self.create_geometry()</span></tt>.
  1401. :param factor: Number by which to scale.
  1402. :type factor: float
  1403. :rtype : None</p>
  1404. </dd></dl>
  1405. </dd></dl>
  1406. <dl class="class">
  1407. <dt id="cirkuix.Excellon">
  1408. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">Excellon</tt><a class="headerlink" href="#cirkuix.Excellon" title="Permalink to this definition">¶</a></dt>
  1409. <dd><p><em>ATTRIBUTES</em></p>
  1410. <ul class="simple">
  1411. <li><tt class="docutils literal"><span class="pre">tools</span></tt> (dict): The key is the tool name and the value is
  1412. the size (diameter).</li>
  1413. <li><tt class="docutils literal"><span class="pre">drills</span></tt> (list): Each is a dictionary:</li>
  1414. </ul>
  1415. <table border="1" class="docutils">
  1416. <colgroup>
  1417. <col width="31%" />
  1418. <col width="69%" />
  1419. </colgroup>
  1420. <thead valign="bottom">
  1421. <tr class="row-odd"><th class="head">Key</th>
  1422. <th class="head">Value</th>
  1423. </tr>
  1424. </thead>
  1425. <tbody valign="top">
  1426. <tr class="row-even"><td>point</td>
  1427. <td>(Shapely.Point) Where to drill</td>
  1428. </tr>
  1429. <tr class="row-odd"><td>tool</td>
  1430. <td>(str) A key in <tt class="docutils literal"><span class="pre">tools</span></tt></td>
  1431. </tr>
  1432. </tbody>
  1433. </table>
  1434. <dl class="method">
  1435. <dt id="cirkuix.Excellon.parse_lines">
  1436. <tt class="descname">parse_lines</tt><big>(</big><em>elines</em><big>)</big><a class="headerlink" href="#cirkuix.Excellon.parse_lines" title="Permalink to this definition">¶</a></dt>
  1437. <dd><p>Main Excellon parser.</p>
  1438. </dd></dl>
  1439. <dl class="method">
  1440. <dt id="cirkuix.Excellon.scale">
  1441. <tt class="descname">scale</tt><big>(</big><em>factor</em><big>)</big><a class="headerlink" href="#cirkuix.Excellon.scale" title="Permalink to this definition">¶</a></dt>
  1442. <dd><p>Scales geometry on the XY plane in the object by a given factor.
  1443. Tool sizes, feedrates an Z-plane dimensions are untouched.
  1444. :param factor: Number by which to scale the object.
  1445. :type factor: float
  1446. :return: None
  1447. :rtype: NOne</p>
  1448. </dd></dl>
  1449. </dd></dl>
  1450. <dl class="class">
  1451. <dt id="cirkuix.CNCjob">
  1452. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">CNCjob</tt><big>(</big><em>units='in'</em>, <em>kind='generic'</em>, <em>z_move=0.1</em>, <em>feedrate=3.0</em>, <em>z_cut=-0.002</em>, <em>tooldia=0.0</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob" title="Permalink to this definition">¶</a></dt>
  1453. <dd><p>Represents work to be done by a CNC machine.</p>
  1454. <p><em>ATTRIBUTES</em></p>
  1455. <ul class="simple">
  1456. <li><tt class="docutils literal"><span class="pre">gcode_parsed</span></tt> (list): Each is a dictionary:</li>
  1457. </ul>
  1458. <table border="1" class="docutils">
  1459. <colgroup>
  1460. <col width="34%" />
  1461. <col width="66%" />
  1462. </colgroup>
  1463. <thead valign="bottom">
  1464. <tr class="row-odd"><th class="head">Key</th>
  1465. <th class="head">Value</th>
  1466. </tr>
  1467. </thead>
  1468. <tbody valign="top">
  1469. <tr class="row-even"><td>geom</td>
  1470. <td>(Shapely.LineString) Tool path (XY plane)</td>
  1471. </tr>
  1472. <tr class="row-odd"><td>kind</td>
  1473. <td>(string) &#8220;AB&#8221;, A is &#8220;T&#8221; (travel) or
  1474. &#8220;C&#8221; (cut). B is &#8220;F&#8221; (fast) or &#8220;S&#8221; (slow).</td>
  1475. </tr>
  1476. </tbody>
  1477. </table>
  1478. <dl class="method">
  1479. <dt id="cirkuix.CNCjob.gcode_parse">
  1480. <tt class="descname">gcode_parse</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.gcode_parse" title="Permalink to this definition">¶</a></dt>
  1481. <dd><p>G-Code parser (from self.gcode). Generates dictionary with
  1482. single-segment LineString&#8217;s and &#8220;kind&#8221; indicating cut or travel,
  1483. fast or feedrate speed.</p>
  1484. </dd></dl>
  1485. <dl class="method">
  1486. <dt id="cirkuix.CNCjob.generate_from_excellon">
  1487. <tt class="descname">generate_from_excellon</tt><big>(</big><em>exobj</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.generate_from_excellon" title="Permalink to this definition">¶</a></dt>
  1488. <dd><p>Generates G-code for drilling from Excellon object.
  1489. self.gcode becomes a list, each element is a
  1490. different job for each tool in the excellon code.</p>
  1491. </dd></dl>
  1492. <dl class="method">
  1493. <dt id="cirkuix.CNCjob.generate_from_excellon_by_tool">
  1494. <tt class="descname">generate_from_excellon_by_tool</tt><big>(</big><em>exobj</em>, <em>tools='all'</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.generate_from_excellon_by_tool" title="Permalink to this definition">¶</a></dt>
  1495. <dd><p>Creates gcode for this object from an Excellon object
  1496. for the specified tools.
  1497. &#64;param exobj: Excellon object to process
  1498. &#64;type exobj: Excellon
  1499. &#64;param tools: Comma separated tool names
  1500. &#64;type: tools: str
  1501. &#64;return: None</p>
  1502. </dd></dl>
  1503. <dl class="method">
  1504. <dt id="cirkuix.CNCjob.generate_from_geometry">
  1505. <tt class="descname">generate_from_geometry</tt><big>(</big><em>geometry</em>, <em>append=True</em>, <em>tooldia=None</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.generate_from_geometry" title="Permalink to this definition">¶</a></dt>
  1506. <dd><p>Generates G-Code from a Geometry object.</p>
  1507. </dd></dl>
  1508. <dl class="method">
  1509. <dt id="cirkuix.CNCjob.plot">
  1510. <tt class="descname">plot</tt><big>(</big><em>tooldia=None, dpi=75, margin=0.1, color={'C': ['#5E6CFF', '#4650BD'], 'T': ['#F0E24D', '#B5AB3A']}, alpha={'C': 1.0, 'T': 0.3}</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.plot" title="Permalink to this definition">¶</a></dt>
  1511. <dd><p>Creates a Matplotlib figure with a plot of the
  1512. G-code job.</p>
  1513. </dd></dl>
  1514. <dl class="method">
  1515. <dt id="cirkuix.CNCjob.plot2">
  1516. <tt class="descname">plot2</tt><big>(</big><em>axes, tooldia=None, dpi=75, margin=0.1, color={'C': ['#5E6CFF', '#4650BD'], 'T': ['#F0E24D', '#B5AB3A']}, alpha={'C': 1.0, 'T': 0.3}</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.plot2" title="Permalink to this definition">¶</a></dt>
  1517. <dd><p>Plots the G-code job onto the given axes.</p>
  1518. </dd></dl>
  1519. <dl class="method">
  1520. <dt id="cirkuix.CNCjob.polygon2gcode">
  1521. <tt class="descname">polygon2gcode</tt><big>(</big><em>polygon</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.polygon2gcode" title="Permalink to this definition">¶</a></dt>
  1522. <dd><p>Creates G-Code for the exterior and all interior paths
  1523. of a polygon.
  1524. &#64;param polygon: A Shapely.Polygon
  1525. &#64;type polygon: Shapely.Polygon</p>
  1526. </dd></dl>
  1527. <dl class="method">
  1528. <dt id="cirkuix.CNCjob.pre_parse">
  1529. <tt class="descname">pre_parse</tt><big>(</big><em>gtext</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.pre_parse" title="Permalink to this definition">¶</a></dt>
  1530. <dd><p>gtext is a single string with g-code</p>
  1531. </dd></dl>
  1532. <dl class="method">
  1533. <dt id="cirkuix.CNCjob.scale">
  1534. <tt class="descname">scale</tt><big>(</big><em>factor</em><big>)</big><a class="headerlink" href="#cirkuix.CNCjob.scale" title="Permalink to this definition">¶</a></dt>
  1535. <dd><p>Scales all the geometry on the XY plane in the object by the
  1536. given factor. Tool sizes, feedrates, or Z-axis dimensions are
  1537. not altered.
  1538. :param factor: Number by which to scale the object.
  1539. :type factor: float
  1540. :return: None
  1541. :rtype: None</p>
  1542. </dd></dl>
  1543. </dd></dl>
  1544. <dl class="class">
  1545. <dt id="cirkuix.CirkuixObj">
  1546. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">CirkuixObj</tt><big>(</big><em>name</em><big>)</big><a class="headerlink" href="#cirkuix.CirkuixObj" title="Permalink to this definition">¶</a></dt>
  1547. <dd><p>Base type of objects handled in Cirkuix. These become interactive
  1548. in the GUI, can be plotted, and their options can be modified
  1549. by the user in their respective forms.</p>
  1550. <dl class="method">
  1551. <dt id="cirkuix.CirkuixObj.build_ui">
  1552. <tt class="descname">build_ui</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.CirkuixObj.build_ui" title="Permalink to this definition">¶</a></dt>
  1553. <dd><p>Sets up the UI/form for this object.
  1554. &#64;return: None
  1555. &#64;rtype : None</p>
  1556. </dd></dl>
  1557. <dl class="method">
  1558. <dt id="cirkuix.CirkuixObj.deserialize">
  1559. <tt class="descname">deserialize</tt><big>(</big><em>obj_dict</em><big>)</big><a class="headerlink" href="#cirkuix.CirkuixObj.deserialize" title="Permalink to this definition">¶</a></dt>
  1560. <dd><p>Re-builds an object from its serialized version.
  1561. &#64;param obj_dict: Dictionary representing a CirkuixObj
  1562. &#64;type obj_dict: dict
  1563. &#64;return None</p>
  1564. </dd></dl>
  1565. <dl class="method">
  1566. <dt id="cirkuix.CirkuixObj.plot">
  1567. <tt class="descname">plot</tt><big>(</big><em>figure</em><big>)</big><a class="headerlink" href="#cirkuix.CirkuixObj.plot" title="Permalink to this definition">¶</a></dt>
  1568. <dd><p>Extend this method! Sets up axes if needed and
  1569. clears them. Descendants must do the actual plotting.</p>
  1570. </dd></dl>
  1571. <dl class="method">
  1572. <dt id="cirkuix.CirkuixObj.read_form">
  1573. <tt class="descname">read_form</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.CirkuixObj.read_form" title="Permalink to this definition">¶</a></dt>
  1574. <dd><p>Reads form into self.options
  1575. &#64;rtype : None</p>
  1576. </dd></dl>
  1577. <dl class="method">
  1578. <dt id="cirkuix.CirkuixObj.serialize">
  1579. <tt class="descname">serialize</tt><big>(</big><big>)</big><a class="headerlink" href="#cirkuix.CirkuixObj.serialize" title="Permalink to this definition">¶</a></dt>
  1580. <dd><p>Returns a representation of the object as a dictionary so
  1581. it can be later exported as JSON. Override this method.
  1582. &#64;return: Dictionary representing the object
  1583. &#64;rtype: dict</p>
  1584. </dd></dl>
  1585. <dl class="method">
  1586. <dt id="cirkuix.CirkuixObj.setup_axes">
  1587. <tt class="descname">setup_axes</tt><big>(</big><em>figure</em><big>)</big><a class="headerlink" href="#cirkuix.CirkuixObj.setup_axes" title="Permalink to this definition">¶</a></dt>
  1588. <dd><p>1) Creates axes if they don&#8217;t exist. 2) Clears axes. 3) Attaches
  1589. them to figure if not part of the figure. 4) Sets transparent
  1590. background. 5) Sets 1:1 scale aspect ratio.
  1591. &#64;param figure: A Matplotlib.Figure on which to add/configure axes.
  1592. &#64;type figure: matplotlib.figure.Figure
  1593. &#64;return: None</p>
  1594. </dd></dl>
  1595. </dd></dl>
  1596. <dl class="class">
  1597. <dt id="cirkuix.CirkuixGerber">
  1598. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">CirkuixGerber</tt><big>(</big><em>name</em><big>)</big><a class="headerlink" href="#cirkuix.CirkuixGerber" title="Permalink to this definition">¶</a></dt>
  1599. <dd><p>Represents Gerber code.</p>
  1600. </dd></dl>
  1601. <dl class="class">
  1602. <dt id="cirkuix.CirkuixExcellon">
  1603. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">CirkuixExcellon</tt><big>(</big><em>name</em><big>)</big><a class="headerlink" href="#cirkuix.CirkuixExcellon" title="Permalink to this definition">¶</a></dt>
  1604. <dd><p>Represents Excellon code.</p>
  1605. </dd></dl>
  1606. <dl class="class">
  1607. <dt id="cirkuix.CirkuixCNCjob">
  1608. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">CirkuixCNCjob</tt><big>(</big><em>name</em>, <em>units='in'</em>, <em>kind='generic'</em>, <em>z_move=0.1</em>, <em>feedrate=3.0</em>, <em>z_cut=-0.002</em>, <em>tooldia=0.0</em><big>)</big><a class="headerlink" href="#cirkuix.CirkuixCNCjob" title="Permalink to this definition">¶</a></dt>
  1609. <dd><p>Represents G-Code.</p>
  1610. </dd></dl>
  1611. <dl class="class">
  1612. <dt id="cirkuix.CirkuixGeometry">
  1613. <em class="property">class </em><tt class="descclassname">cirkuix.</tt><tt class="descname">CirkuixGeometry</tt><big>(</big><em>name</em><big>)</big><a class="headerlink" href="#cirkuix.CirkuixGeometry" title="Permalink to this definition">¶</a></dt>
  1614. <dd><p>Geometric object not associated with a specific
  1615. format.</p>
  1616. </dd></dl>
  1617. </div>
  1618. <div class="section" id="indices-and-tables">
  1619. <h1>Indices and tables<a class="headerlink" href="#indices-and-tables" title="Permalink to this headline">¶</a></h1>
  1620. <ul class="simple">
  1621. <li><a class="reference internal" href="genindex.html"><em>Index</em></a></li>
  1622. <li><a class="reference internal" href="py-modindex.html"><em>Module Index</em></a></li>
  1623. <li><a class="reference internal" href="search.html"><em>Search Page</em></a></li>
  1624. </ul>
  1625. </div>
  1626. </div>
  1627. <footer>
  1628. <hr/>
  1629. <div role="contentinfo">
  1630. <p>
  1631. &copy; Copyright 2014, Juan Pablo Caram.
  1632. </p>
  1633. </div>
  1634. <a href="https://github.com/snide/sphinx_rtd_theme">Sphinx theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>
  1635. </footer>
  1636. </div>
  1637. </div>
  1638. </section>
  1639. </div>
  1640. </body>
  1641. </html>