cmake build system: visiblity support for clang
[supercollider.git] / Help / OSX / ApplicationStart.html
blob7bbfe80b692644095d34050e9ee13a6db72a3414
1 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
2 <html>
3 <head>
4 <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
5 <meta http-equiv="Content-Style-Type" content="text/css">
6 <title></title>
7 <meta name="Generator" content="Cocoa HTML Writer">
8 <meta name="CocoaVersion" content="824.41">
9 <style type="text/css">
10 p.p1 {margin: 0.0px 0.0px 0.0px 0.0px; font: 13.0px Helvetica}
11 p.p2 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica; min-height: 14.0px}
12 p.p3 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Helvetica}
13 p.p4 {margin: 0.0px 0.0px 0.0px 0.0px; font: 12.0px Monaco; min-height: 16.0px}
14 p.p5 {margin: 0.0px 0.0px 0.0px 0.0px; font: 14.0px Helvetica}
15 p.p6 {margin: 0.0px 0.0px 0.0px 0.0px; font: 14.0px Helvetica; color: #000000; min-height: 17.0px}
16 p.p7 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #0000bf}
17 p.p8 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #000000}
18 p.p9 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #bf0000}
19 p.p10 {margin: 0.0px 0.0px 0.0px 0.0px; font: 9.0px Monaco; color: #000000; min-height: 12.0px}
20 span.s1 {font: 18.0px Helvetica}
21 span.s2 {color: #000000}
22 span.s3 {color: #0000bf}
23 span.s4 {color: #606060}
24 span.Apple-tab-span {white-space:pre}
25 </style>
26 </head>
27 <body>
28 <p class="p1"><span class="s1"><b>ApplicationStart<span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></b></span><b>register functions to be evaluated on Application start</b></p>
29 <p class="p2"><br></p>
30 <p class="p3"><b>Superclass: StartUp</b></p>
31 <p class="p2"><br></p>
32 <p class="p3">Available in OSX SuperCollider.app Only.</p>
33 <p class="p2"><br></p>
34 <p class="p3">ApplicationStart allows you to register functions or objects to perform an action <i>only</i><span class="Apple-converted-space">  </span>on application start.</p>
35 <p class="p3">The functions will be evaluated last; After the library has been compiled, the startup file has run and StartUp actions have been evaluated.</p>
36 <p class="p4"><br></p>
37 <p class="p5"><b>Class Methods</b></p>
38 <p class="p2"><br></p>
39 <p class="p3"><b>*add(object)</b></p>
40 <p class="p2"><br></p>
41 <p class="p3">Registers an object or function.</p>
42 <p class="p3">Objects will be receive a doOnApplcationStart message on application start. Functions will be evaluated. <span class="Apple-converted-space"> </span></p>
43 <p class="p2"><br></p>
44 <p class="p3"><b>*remove(object)</b></p>
45 <p class="p2"><br></p>
46 <p class="p3">Removes a function that was previously registered.</p>
47 <p class="p2"><br></p>
48 <p class="p3"><b>*run</b></p>
49 <p class="p2"><br></p>
50 <p class="p3">evaluates the functions or objects in order.</p>
51 <p class="p2"><br></p>
52 <p class="p3">See also [<b>StartUp</b>] for functions that are evaluated <i>every</i> time the ClassLibrary is recompiled.</p>
53 <p class="p2"><br></p>
54 <p class="p2"><br></p>
55 <p class="p5"><b>Examples</b></p>
56 <p class="p6"><br></p>
57 <p class="p7">SomeStartClass<span class="s2"> {</span></p>
58 <p class="p8"><span class="Apple-tab-span"> </span>*initClass {</p>
59 <p class="p7"><span class="s2"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span>ApplicationStart<span class="s2">.add {</span></p>
60 <p class="p9"><span class="s2"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span></span>// something to do when the app has been launched...</p>
61 <p class="p8"><span class="Apple-tab-span"> </span><span class="Apple-tab-span"> </span>}</p>
62 <p class="p10"><span class="Apple-tab-span"> </span></p>
63 <p class="p10"><span class="Apple-tab-span"> </span></p>
64 <p class="p8"><span class="Apple-tab-span"> </span>}</p>
65 <p class="p8">}</p>
66 <p class="p10"><br></p>
67 <p class="p9">// or...</p>
68 <p class="p7">SomeStartClass<span class="s2"> {</span></p>
69 <p class="p8"><span class="Apple-converted-space">       </span>*initClass {</p>
70 <p class="p8"><span class="Apple-converted-space">               </span><span class="s3">ApplicationStart</span>.add(<span class="s3">this</span>);</p>
71 <p class="p8"><span class="Apple-converted-space">       </span>}</p>
72 <p class="p10"><br></p>
73 <p class="p8"><span class="Apple-converted-space">       </span>*doOnApplicationStart { <span class="s4">"something started"</span>.postln }</p>
74 <p class="p8">}</p>
75 <p class="p10"><br></p>
76 <p class="p10"><br></p>
77 </body>
78 </html>