Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

remove trailing whitespaces

  • Loading branch information...
commit d769495d25008dfd30b07a4128aa922d5e46dff6 1 parent 8e140ad
Tim Blechmann authored
Showing with 6,335 additions and 6,335 deletions.
  1. +2 −2 Headers/app/ControlSpec.h
  2. +5 −5 Headers/app/DrawBackground.h
  3. +1 −1  Headers/app/GoToPanel.h
  4. +1 −1  Headers/app/MyDocument.h
  5. +20 −20 Headers/app/SCCocoaView.h
  6. +1 −1  Headers/app/SCGeom.h
  7. +10 −10 Headers/app/SCImage.h
  8. +10 −10 Headers/app/SCSoundFileView.h
  9. +2 −2 Headers/app/SCTextView.h
  10. +122 −122 Headers/app/SCView.h
  11. +5 −5 Headers/app/SMLAdvancedFind/ICU/ICUMatcher.h
  12. +2 −2 Headers/app/SMLAdvancedFind/ICU/ICUPattern.h
  13. +10 −10 Headers/app/SMLAdvancedFind/ICU/LICENSE.txt
  14. +10 −10 Headers/app/SMLAdvancedFind/SMLAdvancedFindController.h
  15. +5 −5 Headers/app/SMLAdvancedFind/SMLStatusBarTextFieldCell.h
  16. +5 −5 Headers/app/TabletEvents.h
  17. +1 −1  Headers/app/UserPanel.h
  18. +60 −60 Headers/app/iPhone/iPhoneSCView.h
  19. +49 −49 Headers/common/SC_AllocPool.h
  20. +4 −4 Headers/common/SC_Altivec.h
  21. +1 −1  Headers/common/SC_Endian.h
  22. +2 −2 Headers/common/SC_FIFO.h
  23. +1 −1  Headers/common/SC_Reply.h
  24. +1 −1  Headers/common/SC_StandAloneInfo_Darwin.h
  25. +1 −1  Headers/common/SC_VFP11.h
  26. +3 −3 Headers/common/SC_fftlib.h
  27. +1 −1  Headers/common/sc_popen.h
  28. +3 −3 Headers/common/scsynthsend.h
  29. +1 −1  Headers/icu/LICENSE.html
  30. +4 −4 Headers/icu/unicode/parseerr.h
  31. +4 −4 Headers/icu/unicode/platform.h
  32. +6 −6 Headers/icu/unicode/putil.h
  33. +1 −1  Headers/icu/unicode/uconfig.h
  34. +1 −1  Headers/icu/unicode/uiter.h
  35. +7 −7 Headers/icu/unicode/umachine.h
  36. +39 −39 Headers/icu/unicode/uregex.h
  37. +49 −49 Headers/icu/unicode/ustring.h
  38. +3 −3 Headers/icu/unicode/utf.h
  39. +2 −2 Headers/icu/unicode/utf16.h
  40. +4 −4 Headers/icu/unicode/utf8.h
  41. +24 −24 Headers/icu/unicode/uversion.h
  42. +5 −5 Headers/lang/AdvancingAllocPool.h
  43. +10 −10 Headers/lang/FIFOT.h
  44. +47 −47 Headers/lang/GC.h
  45. +36 −36 Headers/lang/HashTable.h
  46. +1 −1  Headers/lang/OSCData.h
  47. +64 −64 Headers/lang/Opcodes.h
  48. +7 −7 Headers/lang/PowerOfTwoAllocPool.h
  49. +4 −4 Headers/lang/PriorityQueue.h
  50. +54 −54 Headers/lang/PyrArchiverT.h
  51. +21 −21 Headers/lang/PyrDeepCopier.h
  52. +16 −16 Headers/lang/PyrDeepFreezer.h
  53. +1 −1  Headers/lang/PyrErrors.h
  54. +1 −1  Headers/lang/PyrFilePrim.h
  55. +28 −28 Headers/lang/PyrKernel.h
  56. +5 −5 Headers/lang/PyrKernelProto.h
  57. +1 −1  Headers/lang/PyrLexer.h
  58. +6 −6 Headers/lang/PyrMessage.h
  59. +31 −31 Headers/lang/PyrObject.h
  60. +25 −25 Headers/lang/PyrParseNode.h
  61. +8 −8 Headers/lang/PyrSignal.h
  62. +17 −17 Headers/lang/PyrSlot.h
  63. +5 −5 Headers/lang/PyrSymbol.h
  64. +6 −6 Headers/lang/PyrSymbolTable.h
  65. +12 −12 Headers/lang/ReadWriteMacros.h
  66. +1 −1  Headers/lang/SCBase.h
  67. +7 −7 Headers/lang/SC_ComPort.h
  68. +1 −1  Headers/lang/SC_LibraryConfig.h
  69. +22 −22 Headers/lang/SC_List.h
  70. +2 −2 Headers/lang/SC_Msg.h
  71. +9 −9 Headers/lang/SC_UnorderedList.h
  72. +1 −1  Headers/lang/Samp.h
  73. +3 −3 Headers/lang/VMGlobals.h
  74. +1 −1  Headers/plugin_interface/Hash.h
  75. +1 −1  Headers/plugin_interface/SC_DemandUnit.h
  76. +8 −8 Headers/plugin_interface/SC_Graph.h
  77. +55 −55 Headers/plugin_interface/SC_InlineBinaryOp.h
  78. +6 −6 Headers/plugin_interface/SC_InlineUnaryOp.h
  79. +20 −20 Headers/plugin_interface/SC_InterfaceTable.h
  80. +3 −3 Headers/plugin_interface/SC_Node.h
  81. +14 −14 Headers/plugin_interface/SC_RGen.h
  82. +1 −1  Headers/plugin_interface/SC_Rate.h
  83. +1 −1  Headers/plugin_interface/SC_SndBuf.h
  84. +2 −2 Headers/plugin_interface/SC_Types.h
  85. +8 −8 Headers/plugin_interface/SC_Unit.h
  86. +1 −1  Headers/plugin_interface/SC_Wire.h
  87. +19 −19 Headers/plugin_interface/SC_World.h
  88. +13 −13 Headers/plugin_interface/SC_WorldOptions.h
  89. +6 −6 Headers/plugin_interface/Unroll.h
  90. +19 −19 Headers/plugin_interface/clz.h
  91. +3 −3 Headers/plugin_interface/sc_msg_iter.h
  92. +40 −40 Headers/server/HashTable.h
  93. +5 −5 Headers/server/MsgFifo.h
  94. +7 −7 Headers/server/PriorityQueue.h
  95. +5 −5 Headers/server/ReadWriteMacros.h
  96. +2 −2 Headers/server/Rendezvous.h
  97. +2 −2 Headers/server/SC_AU.h
  98. +12 −12 Headers/server/SC_ComPort.h
  99. +7 −7 Headers/server/SC_Complex.h
  100. +31 −31 Headers/server/SC_CoreAudio.h
  101. +7 −7 Headers/server/SC_GraphDef.h
  102. +1 −1  Headers/server/SC_Group.h
  103. +10 −10 Headers/server/SC_HiddenWorld.h
  104. +3 −3 Headers/server/SC_Lib.h
  105. +9 −9 Headers/server/SC_Lib_Cintf.h
  106. +22 −22 Headers/server/SC_List.h
  107. +1 −1  Headers/server/SC_Prototypes.h
  108. +80 −80 Headers/server/SC_SequencedCommand.h
  109. +1 −1  Headers/server/SC_SynthDef.h
  110. +1 −1  Headers/server/SC_UnitDef.h
  111. +1 −1  Headers/server/SC_UnitSpec.h
  112. +199 −199 Psycollider/Psycollider/Psycollider.py
  113. +7 −7 Psycollider/Psycollider/setup.py
  114. +11 −11 Psycollider/PySCLang/PySCLang_Module.cpp
  115. +4 −4 Psycollider/PySCLang/PySCLang_Module.h
  116. +12 −12 Psycollider/PySCLang/PySCLang_Module_GUIStuff.cpp
  117. +3 −3 Psycollider/PySCLang/PySCLang_VM.h
  118. +8 −8 Psycollider/PySCLang/PySCLang_vpost_stuff.cpp
  119. +10 −10 Psycollider/PySCLang/ReadMe.txt
  120. +2 −2 Psycollider/PySCLang/pycxx/README.html
  121. +2 −2 Psycollider/PySCLang/pycxx/Src/cxxextensions.c
  122. +6 −6 Psycollider/PySCLang/setup.py
  123. +1 −1  README IPHONE
  124. +9 −9 README LINUX
  125. +9 −9 README OS X
  126. +9 −9 SConstruct
  127. +10 −10 Source/app/SMLAdvancedFind/ICU/LICENSE.txt
  128. +3 −3 Source/app/iPhone/LiveCodingView.h
  129. +2 −2 Source/app/iPhone/iSCLangController.h
  130. +1 −1  Source/app/iPhone/isclangAppDelegate.h
  131. +51 −51 Source/common/SC_AllocPool.cpp
  132. +9 −9 Source/common/SC_DirUtils.cpp
  133. +5 −5 Source/common/SC_StandAloneInfo_Darwin.cpp
  134. +11 −11 Source/common/SC_Win32Utils.cpp
  135. +15 −15 Source/common/SC_fftlib.cpp
  136. +1 −1  Source/common/dtoa.c
  137. +107 −107 Source/common/fftlib.c
  138. +2 −2 Source/common/g_fmt.c
  139. +3 −3 Source/common/iPhone/DirBrowserView.h
  140. +18 −18 Source/common/sc_popen.cpp
  141. +5 −5 Source/lang/LangPrimSource/HID_Utilities/HID_Error_Handler.c
  142. +2 −2 Source/lang/LangPrimSource/HID_Utilities/HID_Error_Handler.h
  143. +5 −5 Source/lang/LangPrimSource/HID_Utilities/HID_Name_Lookup.c
  144. +2 −2 Source/lang/LangPrimSource/HID_Utilities/HID_Name_Lookup.h
  145. +10 −10 Source/lang/LangPrimSource/HID_Utilities/HID_Queue_Utilities.c
  146. +1 −1  Source/lang/LangPrimSource/HID_Utilities/HID_Queue_Utilities.h
  147. +5 −5 Source/lang/LangPrimSource/HID_Utilities/HID_Utilities.c
  148. +7 −7 Source/lang/LangPrimSource/HID_Utilities/HID_Utilities.h
  149. +6 −6 Source/lang/LangPrimSource/HID_Utilities/HID_Utilities_External.h
  150. +1 −1  Source/lang/LangPrimSource/HID_Utilities/HID_Utilities_Internal.h
  151. +120 −120 Source/lang/LangPrimSource/OSCData.cpp
  152. +16 −16 Source/lang/LangPrimSource/PyrArchiver.cpp
  153. +215 −215 Source/lang/LangPrimSource/PyrArrayPrimitives.cpp
  154. +11 −11 Source/lang/LangPrimSource/PyrBitPrim.cpp
  155. +53 −53 Source/lang/LangPrimSource/PyrCharPrim.cpp
  156. +252 −252 Source/lang/LangPrimSource/PyrFilePrim.cpp
  157. +70 −70 Source/lang/LangPrimSource/PyrListPrim.cpp
  158. +190 −190 Source/lang/LangPrimSource/PyrMathPrim.cpp
  159. +1 −1  Source/lang/LangPrimSource/PyrPlatformPrim.cpp
  160. +418 −418 Source/lang/LangPrimSource/PyrPrimitive.cpp
  161. +96 −96 Source/lang/LangPrimSource/PyrSched.cpp
  162. +6 −6 Source/lang/LangPrimSource/PyrSerialPrim.cpp
  163. +103 −103 Source/lang/LangPrimSource/PyrSignalPrim.cpp
  164. +64 −64 Source/lang/LangPrimSource/PyrStringPrim.cpp
  165. +25 −25 Source/lang/LangPrimSource/PyrSymbolPrim.cpp
  166. +13 −13 Source/lang/LangPrimSource/PyrUStringPrim.cpp
  167. +26 −26 Source/lang/LangPrimSource/PyrUnixPrim.cpp
  168. +38 −38 Source/lang/LangPrimSource/SC_AlsaMIDI.cpp
  169. +41 −41 Source/lang/LangPrimSource/SC_ComPort.cpp
  170. +13 −13 Source/lang/LangPrimSource/SC_CoreAudioPrim.cpp
  171. +72 −72 Source/lang/LangPrimSource/SC_CoreMIDI.cpp
  172. +80 −80 Source/lang/LangPrimSource/SC_HID.cpp
  173. +9 −9 Source/lang/LangPrimSource/SC_LID.cpp
  174. +45 −45 Source/lang/LangPrimSource/SC_PortMIDI.cpp
  175. +17 −17 Source/lang/LangPrimSource/SC_Speech.cpp
  176. +124 −124 Source/lang/LangPrimSource/SC_Wii.cpp
  177. +3 −3 Source/lang/LangPrimSource/WiiMote_OSX/HISTORY.txt
  178. +142 −142 Source/lang/LangPrimSource/WiiMote_OSX/wiiremote.c
  179. +13 −13 Source/lang/LangPrimSource/WiiMote_OSX/wiiremote.h
  180. +2 −2 Source/lang/LangSource/AdvancingAllocPool.cpp
  181. +246 −246 Source/lang/LangSource/Bison/lang11d_tab.cpp
  182. +3 −3 Source/lang/LangSource/ByteCodeArray.cpp
  183. +14 −14 Source/lang/LangSource/DumpParseNode.cpp
  184. +143 −143 Source/lang/LangSource/GC.cpp
  185. +2 −2 Source/lang/LangSource/InitAlloc.cpp
  186. +4 −4 Source/lang/LangSource/PyrFileUtils.cpp
  187. +411 −411 Source/lang/LangSource/PyrInterpreter3.cpp
  188. +257 −257 Source/lang/LangSource/PyrLexer.cpp
  189. +101 −101 Source/lang/LangSource/PyrMathOps.cpp
  190. +824 −824 Source/lang/LangSource/PyrMathSupport.cpp
  191. +110 −110 Source/lang/LangSource/PyrMessage.cpp
Sorry, we could not display the entire diff because too many files (717) changed.
View
4 Headers/app/ControlSpec.h
@@ -23,11 +23,11 @@ struct ControlSpec {
float minval, maxval, initial;
int numticks;
bool constrained;
-
+
ControlSpec();
};
-inline ControlSpec()
+inline ControlSpec()
: minval(0.), maxval(1.), initial(0.), numticks(11), constrained(false)
{
}
View
10 Headers/app/DrawBackground.h
@@ -53,7 +53,7 @@ class GradientBackground : public DrawBackground
GradientBackground(SCColor inStartColor, SCColor inEndColor, int inDirection, int inSteps);
virtual ~GradientBackground() {}
virtual void drawSelf(CGContextRef cgc, CGRect rect);
-
+
protected:
SCColor mStartColor, mEndColor;
int mDirection, mSteps;
@@ -64,9 +64,9 @@ class HiliteGradientBackground : public GradientBackground
public:
HiliteGradientBackground(SCColor inStartColor, SCColor inEndColor, int inDirection, int inSteps, float inFrac = .33);
virtual ~HiliteGradientBackground() {}
-
+
virtual void drawSelf(CGContextRef cgc, CGRect rect);
-
+
protected:
float mFrac, mFrac1;
};
@@ -100,9 +100,9 @@ class TiledBackground : public DrawBackground
{
public:
TiledBackground(NSImage* inTile);
-
+
virtual void drawSelf(CGContextRef cgc, CGRect rect);
-
+
protected:
NSImage* mTile;
CGRect mTiledBounds;
View
2  Headers/app/GoToPanel.h
@@ -5,7 +5,7 @@
* Created by j. trutzschler on 02 sept 2003.
derived from TextFinder.m by Ali Ozer
- a panel that searches and selects a line
+ a panel that searches and selects a line
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
View
2  Headers/app/MyDocument.h
@@ -109,7 +109,7 @@ extern PyrSymbol *s_closed;
- (IBAction)advancedFindReplaceAction:(id)sender;
- (void) callSCLangWithMethod: (PyrSymbol*) method;
- (BOOL) promptToSave;
-- (void) setPromptToSave: (BOOL) flag;
+- (void) setPromptToSave: (BOOL) flag;
- (void) keyUp: (NSEvent*) event;
- (void) keyDown: (NSEvent*) event;
- (BOOL) handleKeyDown: (NSEvent*) event;
View
40 Headers/app/SCCocoaView.h
@@ -105,8 +105,8 @@
class SCCocoaTextView : public SCView
{
-public:
- SCCocoaTextView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCCocoaTextView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCCocoaTextView();
virtual void makeFocus(bool focus);
virtual void setBounds(SCRect inBounds);
@@ -114,20 +114,20 @@ class SCCocoaTextView : public SCView
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual void keyDown(int character, int modifiers, unsigned short keycode);
virtual void keyUp(int character, int modifiers, unsigned short keycode);
-
+
SCTextView* getTextView(){return mTextView;};
void tabPrevFocus();
void tabNextFocus();
virtual void setVisibleFromParent();
void setLoadLinkInView(bool flag){mLoadLinkInView = flag;};
bool getLoadLinkInView(){return mLoadLinkInView;};
-
+
int open(NSString *path);
NSURL* getLastURL() {return mLastURL;};
bool linkAction(NSString *path);
-
+
virtual NSView* focusResponder() { return mTextView; }
-
+
protected:
SCTextView *mTextView;
NSScrollView *mScrollView;
@@ -138,8 +138,8 @@ class SCCocoaTextView : public SCView
class SCMovieView : public SCView
{
-public:
- SCMovieView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCMovieView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCMovieView();
virtual void setBounds(SCRect inBounds);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -152,14 +152,14 @@ class SCMovieView : public SCView
/* QT */
TimeBase mTimeBase;
TimeRecord mTimeRecord;
- Movie mMovie;
+ Movie mMovie;
};
//class SCTextField : public SCStaticText
class SCTextField : public SCView
{
-public:
- SCTextField(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCTextField(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCTextField();
virtual void setBounds(SCRect inBounds);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -181,14 +181,14 @@ class SCTextField : public SCView
SCTextFieldResponder *mTextField;
SCColor mBoxColor;
//SCTextFieldResponder *mCocoaToLangAction;
-
+
SCColor mStringColor;
};
class SCNumberBox2 : public SCTextField
{
-public:
- SCNumberBox2(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCNumberBox2(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCNumberBox2();
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -204,8 +204,8 @@ class SCNumberBox2 : public SCTextField
class SCQuartzComposerView : public SCView
{
-public:
- SCQuartzComposerView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCQuartzComposerView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCQuartzComposerView();
virtual void setBounds(SCRect inBounds);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -214,15 +214,15 @@ class SCQuartzComposerView : public SCView
virtual int getSCObjectForNSObject(PyrSlot *slot, id nsObject, NSString *type);
virtual void setVisibleFromParent();
virtual NSView* focusResponder() { return mQCView; }
-
+
protected:
QCView *mQCView;
};
class SCLevelIndicator : public SCView
{
- public:
- SCLevelIndicator(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ public:
+ SCLevelIndicator(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCLevelIndicator();
virtual void setBounds(SCRect inBounds);
void setImage();
@@ -233,7 +233,7 @@ class SCLevelIndicator : public SCView
void tabPrevFocus();
void tabNextFocus();
virtual NSView* focusResponder() { return mLevelIndicator; }
-
+
protected:
SCNSLevelIndicator *mLevelIndicator;
NSImage *mImage;
View
2  Headers/app/SCGeom.h
@@ -61,7 +61,7 @@ inline SCRect SCRectUnion(SCRect a, SCRect b)
{
if (a.height <= 0. && a.width <= 0.) return b;
if (b.height <= 0. && b.width <= 0.) return a;
-
+
SCRect u;
u.x = sc_min(a.x, b.x);
u.y = sc_min(a.y, b.y);
View
20 Headers/app/SCImage.h
@@ -20,11 +20,11 @@
/*
* SCImage.h
- *
+ *
* SCImage interface
* charles picasso && blackrain 14/08/08.
*/
-
+
#import <Cocoa/Cocoa.h>
#import <QuartzCore/QuartzCore.h>
#import <sys/time.h>
@@ -37,19 +37,19 @@
/*
May be we should force the 10.4 version ??
- with
+ with
#define SCIMAGE_MAC_OS_10_5 0
because it does run with no problem on 10.5
anyway currently in both platform the 10.4 version should be compiled instead of the 10.5
in case of a problem force the 10.4
-
+
Why 2 different versions ?
--------------------------
- CIImageAccumulator does not behave the same with 10.4 SDK on 10.5 : seems like use Generator type Filters
make it refuse to take the CIImage. This crash the app because of an EXEC_BAD_ACCESS later if drawing.
- On 10.4 the CIImageAccumulator is replaced by a plain CIImage : this does not change global behaviour
it just disable the possibility to use Dirty Rect wich should be considered as a marginal option for now.
-
+
*/
#define SCIMAGE_MAC_OS_10_4 (MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_4)
//#if defined(MAC_OS_X_VERSION_10_5)
@@ -73,21 +73,21 @@ enum {
// 1_ draw inside the image
// 2_ use direct pixel data manipulation (get/set)
// but definitely better for fast drawing and accelerated image processing techniques (CoreImageFilters)
-
+
SCImageDoNotUseGraphicsAcceleration = 1 // SCImage will never use CIImage - better performance if user always update the bitmap representation
- // using standard Quartz techniques like :
+ // using standard Quartz techniques like :
// 1_ drawing inside the Image (with lockFocus - unlockFocus)
// 2_ or using a lot direct pixel data manipulation (get/set)
};
typedef int SCImageHint;
-@interface SCImage : NSObject
+@interface SCImage : NSObject
{
@public
#if SC_IMAGE_MAC_OS_10_5
CIImageAccumulator *_ciimageStore; // accumulator
#else
- CIImage *_ciimage; // in 10.4
+ CIImage *_ciimage; // in 10.4
#endif
//@private
CIFormat _ciFormat; // hint for prefered format when processing CoreImages
@@ -103,7 +103,7 @@ typedef int SCImageHint;
BOOL _bitmapSynced; // is bitmap rep in sync
BOOL _ciimageSynced; // is ciimage rep in sync
BOOL _savedCtxState; // flag used for lockFocus - unlockFocus
-
+
void* _cache; // used to cache reps : might be a CGLayerRef / NSImage / CGPattern (CGLayerRef are cached to GPU when possible)
}
- (id)initWithContentsOfURL:(NSURL*)url isAccelerated:(BOOL)yorn format:(CIFormat)fmt;
View
20 Headers/app/SCSoundFileView.h
@@ -56,10 +56,10 @@ const int kMaxSndSelections = 64;
const int kMaxSndChannels = 16;
class SCSoundFileView : public SCView
{
-public:
- SCSoundFileView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCSoundFileView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCSoundFileView();
-
+
virtual void draw(SCRect inDamage);
virtual void draw0(SCRect inDamage, CGContextRef cgc);
virtual void draw1(SCRect inDamage, CGContextRef cgc);
@@ -75,14 +75,14 @@ class SCSoundFileView : public SCView
// virtual void mouseOver(SCPoint where);
virtual int findSelection(int frame);
virtual void setBounds(SCRect inbounds);
-
- SCPoint pixelToUnits(SCPoint p, SCRect r)
- {
+
+ SCPoint pixelToUnits(SCPoint p, SCRect r)
+ {
return SCMakePoint(
(p.x - r.x) * mZoom.x + mScroll.x,
(p.y - r.y) * mZoom.y + mScroll.y);
}
- SCPoint unitsToPixel(SCPoint u, SCRect r)
+ SCPoint unitsToPixel(SCPoint u, SCRect r)
{
return SCMakePoint(
(u.x - mScroll.x) * mInvZoom.x + r.x,
@@ -90,18 +90,18 @@ class SCSoundFileView : public SCView
}
protected:
-
+
int mBufNum;
SNDFILE *mSndFile;
SndMinMaxBuf mSndMinMax;
- SndBuf mSndBuf;
+ SndBuf mSndBuf;
SCPoint mZoom, mInvZoom, mScroll;
int mStyle; // 0 = separate, 1 = overlay, 2 = x,y.
SCColor mWaveColors[kMaxSndChannels];
SCColor mGridColor;
bool mGridOn;
float mGridResolution;
- int mGridOffset;
+ int mGridOffset;
SCPoint mAbsolutePosition;
bool mIsReadingSoundFile;
int mCurrentSelection;
View
4 Headers/app/SCTextView.h
@@ -26,7 +26,7 @@ typedef unsigned long NSUInteger;
#else
typedef int NSInteger;
typedef unsigned int NSUInteger;
-#endif
+#endif
@interface SCTextView : NSTextView
{
@@ -46,7 +46,7 @@ typedef unsigned int NSUInteger;
- (NSString*)currentlySelectedTextOrLine: (NSRange*) outRange;
- (NSString*)currentlySelectedText: (NSRange*) outRange;
- (void) setLangClassToCall: (NSString*) stringin withKeyDownActionIndex:(int) downIndex withKeyUpActionIndex:(int) upIndex ;
-- (void) setObjectKeyDownActionIndex:(int) mindex setObjectKeyUpActionIndex:(int) downIndex;
+- (void) setObjectKeyDownActionIndex:(int) mindex setObjectKeyUpActionIndex:(int) downIndex;
- (void)setDefaultTabsTo:(float)value;
- (IBAction)openCode:(id)sender;
- (IBAction) showHelp: (id) sender;
View
244 Headers/app/SCView.h
@@ -69,7 +69,7 @@ struct SCViewMaker
{
SCViewMaker(const char* inName, SCViewCtor inCtor);
static SCView* MakeSCView(PyrObject* inObj, SCContainerView *inParent, SCRect inBounds, const char* classname);
-
+
SCViewMaker *mNext;
SCViewCtor mCtor;
const char* mName;
@@ -81,9 +81,9 @@ extern SCView *gAnimatedViews;
class SCView
{
public:
- SCView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCView();
-
+
virtual void draw(SCRect inDamage);
virtual void drawFocus(SCRect inDamage);
virtual void drawDisabled(SCRect inDamage);
@@ -105,22 +105,22 @@ class SCView
void setConstructionModeFromPoint(SCPoint where);
virtual bool shouldDim();
void beginDrag(SCPoint where);
-
+
virtual bool canReceiveDrag();
virtual void receiveDrag();
-
+
bool isFocus() const;
bool hit(SCPoint p) const;
void refresh();
virtual void refreshInRect(SCRect b);
void refreshFocus();
void setDragHilite(bool inFlag);
-
+
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
-
+
virtual void setVisibleFromParent() { } // does nothing, needed for Cocoa views
-
+
virtual bool isDragSource() const;
virtual SCView* findView(SCPoint where);
virtual SCView* findViewByID(int32 inID);
@@ -138,29 +138,29 @@ class SCView
virtual Layout getLayout();
// virtual void setLayout(Layout inLayout);
-
+
SCView* next() { return mNext; }
SCContainerView* parent() { return mParent; }
-
+
virtual NSMenu* contextMenu(SCPoint inPoint);
-
+
virtual void setMenuItemChosen(int inItem) {}
-
+
PyrObject* GetSCObj() { return mObj; }
SCView* NextAnimatedView() const { return mNextAnimatedView; }
-
+
void startAnimation();
void stopAnimation();
virtual void animate() { refresh(); }
-
+
virtual bool isScroller() { return false; }
virtual bool isSubViewScroller() { return false; }
virtual bool isContainer() { return false; }
virtual SCRect checkMinimumSize() { return mBounds; }
virtual bool relativeOrigin() {return false;}
-
+
bool isTopContainer(){ return (!mParent);};
-
+
protected:
friend class SCContainerView;
friend class SCScrollView;
@@ -190,11 +190,11 @@ class SCView
class SCContainerView : public SCView
{
public:
- SCContainerView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCContainerView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCContainerView();
-
+
virtual void drawIfNecessary(SCRect inDamage);
-
+
virtual void add(SCView *inChild);
virtual void remove(SCView *inChild);
virtual SCView* findView(SCPoint where);
@@ -209,17 +209,17 @@ class SCContainerView : public SCView
virtual bool isVisible() {return mVisible && mParent->isVisible(); }
virtual bool relativeOrigin() {return mRelativeOrigin;}
virtual bool isContainer() { return true; }
-
+
protected:
SCView *mChildren;
int mNumChildren;
- bool mRelativeOrigin;
+ bool mRelativeOrigin;
};
class SCCompositeView : public SCContainerView
{
public:
- SCCompositeView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCCompositeView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCCompositeView();
virtual void setBounds(SCRect inBounds);
@@ -229,9 +229,9 @@ class SCCompositeView : public SCContainerView
class SCLayoutView : public SCContainerView
{
public:
- SCLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCLayoutView();
-
+
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual void add(SCView *inChild);
@@ -243,18 +243,18 @@ class SCLayoutView : public SCContainerView
class SCHLayoutView : public SCLayoutView
{
public:
- SCHLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCHLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCHLayoutView();
virtual void setBounds(SCRect inBounds);
-
+
protected:
};
class SCVLayoutView : public SCLayoutView
{
public:
- SCVLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCVLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCVLayoutView();
virtual void setBounds(SCRect inBounds);
@@ -270,12 +270,12 @@ class SCTopView : public SCCompositeView
{
public:
SCTopView(PyrObject* inObj, SCRect inBounds);
-
- SCView *focusView() {
+
+ SCView *focusView() {
if(isSubViewScroller()) {
return mTop->focusView();
} else {
- return mFocusView;
+ return mFocusView;
}
}
@@ -284,34 +284,34 @@ class SCTopView : public SCCompositeView
void resetFocus();
void addDamage(SCRect inRect);
void beginDragCallback(SCPoint where, PyrSlot* slot, NSString* string, NSString* label);
-
+
void setDamageCallback(DamageCallback inFunc, void *inHostData)
{ mDamageCallback = inFunc; mHostData = inHostData; }
void setDragCallback(DragCallback inFunc)
{ mDragCallback = inFunc; }
-
+
void tabNextFocus();
void tabPrevFocus();
void setDragView(SCView *inView);
-
+
NSView* GetNSView() { return mNSView; }
void SetNSView(NSView* inView) { mNSView = inView; }
bool ConstructionMode() { return mConstructionMode; }
void SetConstructionMode(bool inFlag) { mConstructionMode = inFlag; }
-
+
virtual void drawFocus(SCRect inDamage);
- virtual bool canReceiveDrag();
+ virtual bool canReceiveDrag();
virtual void receiveDrag();
virtual void setInternalBounds(SCRect internalBounds);
virtual bool isVisible() {return mVisible; }
protected:
friend class SCView;
- void focusIs(SCView *inView) {
+ void focusIs(SCView *inView) {
if(isSubViewScroller()) {
mTop->focusIs(inView);
} else {
- mFocusView = inView;
+ mFocusView = inView;
}
}
@@ -321,7 +321,7 @@ class SCTopView : public SCCompositeView
SCView *mFocusView;
SCView *mDragView;
NSView *mNSView;
-
+
bool mConstructionMode;
};
@@ -334,12 +334,12 @@ class SCScrollTopView : public SCTopView
{
public:
SCScrollTopView(PyrObject* inObj, SCRect inBounds);
-
+
NSScrollView* GetScrollView() { return mNSScrollView; }
void SetNSScrollView(NSScrollView* inView) { mNSScrollView = inView; }
-
+
virtual bool isScroller() { return true; }
-
+
virtual SCRect getDrawBounds();
virtual void setInternalBounds(SCRect inBounds);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -349,7 +349,7 @@ class SCScrollTopView : public SCTopView
virtual void remove(SCView *inChild);
bool isInSetClipViewOrigin() { return mInSetClipViewOrigin; }
void setInSetClipViewOrigin(bool flag) { mInSetClipViewOrigin = flag; }
-
+
protected:
NSScrollView *mNSScrollView;
bool mInSetClipViewOrigin;
@@ -363,14 +363,14 @@ class SCScrollView : public SCScrollTopView
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual void setVisibleFromParent();
//virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
-
+
virtual void setBounds(SCRect inBounds);
virtual SCRect getBounds();
virtual void add(SCView *inChild);
// virtual void remove(SCView *inChild);
-
+
virtual bool isSubViewScroller() { return true; }
-
+
virtual void drawIfNecessary(SCRect inDamage);
virtual void drawSubViewIfNecessary(SCRect inDamage);
virtual bool isVisible() {return mVisible && mParent->isVisible(); }
@@ -381,12 +381,12 @@ inline bool SCView::isFocus() const { return mTop->focusView() == this; }
class SCSlider : public SCView
{
-public:
- SCSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual void draw(SCRect inDamage);
virtual void mouseTrack(SCPoint where, int modifiers,NSEvent *theEvent);
-
+
double value() { return mValue; }
bool setValue(double inValue, bool send);
@@ -399,7 +399,7 @@ class SCSlider : public SCView
protected:
virtual void setValueFromPoint(SCPoint point);
void calcThumbRect(SCRect bounds);
-
+
SCRect mThumbRect;
double mValue, mStepSize, mStepScale;
DrawBackground* mKnob;
@@ -410,13 +410,13 @@ SCView* NewSCSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds
class SCRangeSlider : public SCView
{
-public:
- SCRangeSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCRangeSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual void draw(SCRect inDamage);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseTrack(SCPoint where, int modifiers,NSEvent *theEvent);
-
+
bool setValue(double inLo, double inHi, bool send);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -433,7 +433,7 @@ class SCRangeSlider : public SCView
void adjustHiFromPoint(SCPoint point);
// sc.solar addition end
void calcRangeRect();
-
+
SCRect mRangeRect;
double mLo, mHi, mStepSize, mStepScale;
SCPoint mAnchor;
@@ -445,12 +445,12 @@ SCView* NewSCRangeSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inB
class SC2DSlider : public SCView
{
-public:
- SC2DSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SC2DSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual void draw(SCRect inDamage);
virtual void mouseTrack(SCPoint where, int modifiers,NSEvent *theEvent);
-
+
virtual bool setValue(double inLo, double inHi, bool send);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -462,7 +462,7 @@ class SC2DSlider : public SCView
protected:
virtual void setValueFromPoint(SCPoint point);
void calcThumbRect();
-
+
SCRect mThumbRect;
double mX, mY;
double mStepSize, mStepScale;
@@ -473,7 +473,7 @@ SCView* NewSC2DSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBoun
class SC2DTabletSlider : public SC2DSlider
{
-public:
+public:
SC2DTabletSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
@@ -481,12 +481,12 @@ class SC2DTabletSlider : public SC2DSlider
virtual void mouseEndTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseDownAction(SCPoint where, int modifiers, NSEvent *theEvent);
virtual void mouseMoveAction(SCPoint where, int modifiers, NSEvent *theEvent);
- virtual void mouseUpAction(SCPoint where, int modifiers, NSEvent *theEvent);
+ virtual void mouseUpAction(SCPoint where, int modifiers, NSEvent *theEvent);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual bool setValue(double inX, double inY,bool send);
-protected:
+protected:
int mClipInBounds;
};
@@ -498,27 +498,27 @@ SCView* NewSC2DTabletSlider(SCContainerView *inParent, PyrObject* inObj, SCRect
const int kMaxScopeChannels = 16;
class SCScope : public SCView
{
-public:
- SCScope(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCScope(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCScope();
-
+
virtual void draw(SCRect inDamage);
virtual void draw0(CGContextRef cgc);
virtual void draw1(CGContextRef cgc);
virtual void draw2(CGContextRef cgc);
virtual void mouseTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void animate();
-
+
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
- SCPoint pixelToUnits(SCPoint p, SCRect r)
- {
+ SCPoint pixelToUnits(SCPoint p, SCRect r)
+ {
return SCMakePoint(
(p.x - r.x) * mZoom.x + mScroll.x,
(p.y - r.y) * mZoom.y + mScroll.y);
}
- SCPoint unitsToPixel(SCPoint u, SCRect r)
+ SCPoint unitsToPixel(SCPoint u, SCRect r)
{
return SCMakePoint(
(u.x - mScroll.x) * mInvZoom.x + r.x,
@@ -526,7 +526,7 @@ class SCScope : public SCView
}
protected:
-
+
int mBufNum;
SndBuf mSndBuf;
SCPoint mZoom, mInvZoom, mScroll;
@@ -551,8 +551,8 @@ const int kFontNameSize = 80;
class SCButton : public SCView
{
-public:
- SCButton(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCButton(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCButton();
virtual void draw(SCRect inDamage);
@@ -568,7 +568,7 @@ class SCButton : public SCView
virtual void receiveDrag();
protected:
-
+
int mValue;
char mFontName[kFontNameSize];
float mFontSize;
@@ -581,13 +581,13 @@ SCView* NewSCButton(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds
class SCPopUpMenu : public SCView
{
-public:
- SCPopUpMenu(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCPopUpMenu(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCPopUpMenu();
virtual void draw(SCRect inDamage);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
-
+
bool setValue(int inValue, bool send);
virtual void setMenuItemChosen(int inItem) { setValue(inItem, true); }
@@ -598,7 +598,7 @@ class SCPopUpMenu : public SCView
virtual void receiveDrag();
protected:
-
+
int mValue;
MenuHandle mMenuH;
char mFontName[kFontNameSize];
@@ -610,14 +610,14 @@ SCView* NewSCPopUpMenu(SCContainerView *inParent, PyrObject* inObj, SCRect inBou
class SCListView : public SCView
{
-public:
- SCListView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCListView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCListView();
virtual void draw(SCRect inDamage);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseTrack(SCPoint where, int modifiers, NSEvent *theEvent);
-
+
bool setValue(int inValue, bool send);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -625,11 +625,11 @@ class SCListView : public SCView
virtual bool canReceiveDrag();
virtual void receiveDrag();
-
+
void scrollToValue();
protected:
-
+
int mValue;
CFMutableArrayRef mArray;
char mFontName[kFontNameSize];
@@ -647,18 +647,18 @@ class SCListView : public SCView
};
SCView* NewSCListView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
-//by jan trutzschler
+//by jan trutzschler
class SCMultiSliderView : public SCView
{
-public:
- SCMultiSliderView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCMultiSliderView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCMultiSliderView();
virtual void draw(SCRect inDamage);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseEndTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseTrack(SCPoint where, int modifiers,NSEvent *theEvent);
-
+
void setSelection(SCPoint where);
bool setValue(int inX, double inY, bool send);
//virtual void setPoint(int x, double y, bool send);
@@ -691,13 +691,13 @@ class SCMultiSliderView : public SCView
SCPoint mPrevPoint;
int mElasticMode;
double mElasticIndexStep;
-
+
};
SCView* NewSCMultiSliderView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
////
//by jan truetzschler jt[at]kandos[dot]de
-//enum taken from PyrArrayPrimitives should move to a header file
+//enum taken from PyrArrayPrimitives should move to a header file
enum {
shape_Step,
shape_Linear,
@@ -716,10 +716,10 @@ struct SCEnvObject {
int mNumConnection;
SCPoint mDrawPoint;
double * mConnections; //tells to where it is connected
- int mNumInputs, mNumOutputs;
+ int mNumInputs, mNumOutputs;
double x, y;
bool mIsSelected, mIsVisible, mEditable;
- char *mString;
+ char *mString;
int shape;
float curve;
};
@@ -727,15 +727,15 @@ typedef struct SCEnvObject SCEnvObject;
class SCEnvelopeView : public SCView
{
-public:
- SCEnvelopeView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCEnvelopeView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCEnvelopeView();
virtual void draw(SCRect inDamage);
virtual void mouseDownAction(SCPoint where, int modifiers, NSEvent *theEvent);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseEndTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseTrack(SCPoint where, int modifiers,NSEvent *theEvent);
-
+
void setSelection(SCPoint where, bool fixed, bool checkForConnection);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -761,7 +761,7 @@ class SCEnvelopeView : public SCView
bool mDrawLinesActive, mShowIndex, mDrawRectsActive, mIsFilled, mIsFixedSelection, mIsEnvView, mIsTracking;
int mSelectedIndex;
SCPoint mMousePoint;
-
+
//grid
bool mGridOn;
SCColor mGridColor;
@@ -776,7 +776,7 @@ class SCEnvelopeView : public SCView
int *drawOrder;
SCPoint trackOffset;
-
+
};
SCView* NewSCEnvelopeView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
@@ -785,14 +785,14 @@ SCView* NewSCEnvelopeView(SCContainerView *inParent, PyrObject* inObj, SCRect in
class SCUserView : public SCView
{
-public:
- SCUserView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCUserView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCUserView();
virtual void draw(SCRect inDamage);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseTrack(SCPoint where, int modifiers,NSEvent *theEvent);
- virtual void mouseEndTrack(SCPoint where, int modifiers,NSEvent *theEvent);
+ virtual void mouseEndTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseMoveAction(SCPoint where, int modifiers, NSEvent *theEvent);
virtual void mouseUpAction(SCPoint where, int modifiers, NSEvent *theEvent);
virtual void mouseDownAction(SCPoint where, int modifiers, NSEvent *theEvent);
@@ -800,7 +800,7 @@ class SCUserView : public SCView
virtual void keyDown(int character, int modifiers);
virtual void keyUp(int character, int modifiers);
virtual bool canReceiveDrag();
- virtual void receiveDrag();
+ virtual void receiveDrag();
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual void clearDrawing();
@@ -813,7 +813,7 @@ class SCUserView : public SCView
#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1040
CGLayerRef mCGLayer;
#endif
-
+
void mouseAction(PyrSymbol *method, SCPoint where, int modifiers);
};
SCView* NewSCUserView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
@@ -827,16 +827,16 @@ enum {
class SCStaticText : public SCView
{
-public:
- SCStaticText(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCStaticText(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCStaticText();
-
+
virtual void draw(SCRect inDamage);
virtual bool shouldDim();
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
-
+
protected:
virtual void drawString(SCRect bounds);
@@ -851,16 +851,16 @@ SCView* NewSCStaticText(SCContainerView *inParent, PyrObject* inObj, SCRect inBo
class SCNumberBox : public SCStaticText
{
-public:
- SCNumberBox(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCNumberBox(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCNumberBox();
-
+
virtual void draw(SCRect inDamage);
virtual bool shouldDim();
virtual void mouseTrack(SCPoint where, int modifiers,NSEvent *theEvent);
//virtual void mouseEndTrack(SCPoint where, int modifiers);
-
+
//virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
//virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -871,14 +871,14 @@ SCView* NewSCNumberBox(SCContainerView *inParent, PyrObject* inObj, SCRect inBou
class SCDragSource : public SCStaticText
{
-public:
- SCDragSource(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCDragSource(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCDragSource();
-
+
virtual void draw(SCRect inDamage);
virtual bool shouldDim();
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
-
+
protected:
};
SCView* NewSCDragSource(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
@@ -886,16 +886,16 @@ SCView* NewSCDragSource(SCContainerView *inParent, PyrObject* inObj, SCRect inBo
class SCDragSink : public SCStaticText
{
-public:
- SCDragSink(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCDragSink(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCDragSink();
-
+
virtual void draw(SCRect inDamage);
virtual bool shouldDim();
-
+
virtual bool canReceiveDrag();
virtual void receiveDrag();
-
+
protected:
};
SCView* NewSCDragSink(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
@@ -903,9 +903,9 @@ SCView* NewSCDragSink(SCContainerView *inParent, PyrObject* inObj, SCRect inBoun
class SCDragBoth : public SCDragSink
{
-public:
- SCDragBoth(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
-
+public:
+ SCDragBoth(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+
virtual void draw(SCRect inDamage);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
@@ -918,10 +918,10 @@ SCView* NewSCDragBoth(SCContainerView *inParent, PyrObject* inObj, SCRect inBoun
//felix
class SCTabletView : public SCView
{
-public:
- SCTabletView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCTabletView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCTabletView();
-
+
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual void mouseBeginTrack(SCPoint where, int modifiers,NSEvent *theEvent);
@@ -929,7 +929,7 @@ class SCTabletView : public SCView
virtual void mouseEndTrack(SCPoint where, int modifiers,NSEvent *theEvent);
virtual void mouseDownAction(SCPoint where, int modifiers, NSEvent *theEvent);
virtual void mouseMoveAction(SCPoint where, int modifiers, NSEvent *theEvent);
- virtual void mouseUpAction(SCPoint where, int modifiers, NSEvent *theEvent);
+ virtual void mouseUpAction(SCPoint where, int modifiers, NSEvent *theEvent);
protected:
int mClipToBounds;
};
View
10 Headers/app/SMLAdvancedFind/ICU/ICUMatcher.h
@@ -21,14 +21,14 @@
/*!
@method matcherWithPattern:overString:
@abstract Returns a matcher that can match the given pattern over the given string.
- @discussion
+ @discussion
*/
+(ICUMatcher *)matcherWithPattern:(ICUPattern *)p overString:(NSString *)stringToSearchOver;
/*!
@method initWithPattern:overString:
@abstract Initializes a matcher that can match the given patter over the given string.
- @discussion
+ @discussion
*/
-(ICUMatcher *)initWithPattern:(ICUPattern *)p overString:(NSString *)stringToSearchOver;
@@ -77,7 +77,7 @@
/*!
@method pattern
@abstract Returns the pattern for this matcher.
- @discussion
+ @discussion
*/
-(ICUPattern *)pattern;
-(void)setPattern:(ICUPattern *)p;
@@ -85,7 +85,7 @@
/*!
@method matches
@abstract Returns YES if the patterns matches the <b>entire</b> input string.
- @discussion
+ @discussion
*/
-(BOOL)matches;
@@ -106,7 +106,7 @@
/*!
@method reset
@abstract Resets any state associated with the matcher and its pattern.
- @discussion
+ @discussion
*/
-(void)reset;
View
4 Headers/app/SMLAdvancedFind/ICU/ICUPattern.h
@@ -23,7 +23,7 @@ extern unsigned UnicodeWordBoundaries;
@class ICUPattern
@abstract A compiled regular expression.
@discussion <a href="http://icu.sourceforge.net/">ICU</a> provides a widely used Unicode
- regular expression library. This class can be roughly mapped to the <a href="http://icu.sourceforge.net/apiref/icu4c/classRegexPattern.html">ICU C++ Pattern class</a>. Notes about ICU regular expressions can be found at the
+ regular expression library. This class can be roughly mapped to the <a href="http://icu.sourceforge.net/apiref/icu4c/classRegexPattern.html">ICU C++ Pattern class</a>. Notes about ICU regular expressions can be found at the
<a href="http://icu.sourceforge.net/userguide/regexp.html">ICU User Guide</a>.
*/
@interface ICUPattern: NSObject <NSCopying> {
@@ -93,7 +93,7 @@ extern unsigned UnicodeWordBoundaries;
@method stringToSearch
@abstract Returns the string that is being searched over with the pattern.
@discussion This method creates an NSString from the underlying UTF16 character array used by ICU. For large
- strings, this may be memory-intensive/time-consuming. Performance-critical applications may want to modify this
+ strings, this may be memory-intensive/time-consuming. Performance-critical applications may want to modify this
class to suite their needs to reduce the number of NSString objects that are created.
*/
-(NSString *)stringToSearch;
View
20 Headers/app/SMLAdvancedFind/ICU/LICENSE.txt
@@ -9,17 +9,17 @@ Copyright (c) 2005-2006, Aaron Evans
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* * Neither the name of Aaron Evans, nor the names of its contributors may
-* be used to endorse or promote products derived from this software
+* be used to endorse or promote products derived from this software
* without specific prior written permission.
*
-* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS ``AS IS''
-* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER AND CONTRIBUTORS ``AS IS''
+* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
-* DISCLAIMED. IN NO EVENT SHALL THE COYPRIGHT HOLDERS AND CONTRIBUTORS AND
-* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
-* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
-* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
-* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
-* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
-* OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+* DISCLAIMED. IN NO EVENT SHALL THE COYPRIGHT HOLDERS AND CONTRIBUTORS AND
+* CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+* OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+* WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+* OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
* ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
View
20 Headers/app/SMLAdvancedFind/SMLAdvancedFindController.h
@@ -4,11 +4,11 @@ Written by Peter Borg, pgw3@mac.com
Find the latest version at http://smultron.sourceforge.net
Copyright 2004-2007 Peter Borg
-
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
*/
@@ -41,29 +41,29 @@ typedef enum {
IBOutlet NSOutlineView *findResultsOutlineView;
// IBOutlet NSView *resultDocumentContentView;
IBOutlet NSTreeController *findResultsTreeController;
-
+
IBOutlet NSSplitView *advancedFindSplitView;
-
+
IBOutlet NSButton *currentDocumentScope;
IBOutlet NSButton *currentProjectScope;
IBOutlet NSButton *allDocumentsScope;
-
+
IBOutlet NSTextView *mTextView;
IBOutlet NSButton *setUseRegularExpressionsButton;
IBOutlet NSButton *setSearchInSelectionButton;
IBOutlet NSButton *setIgnoreCaseButton;
-
+
IBOutlet NSScrollView * mScrollView;
-
+
id currentlyDisplayedDocumentInAdvancedFind;
NSMutableArray *mContents; //search results
IBOutlet NSPanel *regularExpressionsHelpPanel;
-
+
SMLAdvancedFindScope mSearchScope;
NSDocument *mCurrentDocument;
-
+
NSWindowController * myWindowController;
}
View
10 Headers/app/SMLAdvancedFind/SMLStatusBarTextFieldCell.h
@@ -4,11 +4,11 @@ Written by Peter Borg, pgw3@mac.com
Find the latest version at http://smultron.sourceforge.net
Copyright 2004-2007 Peter Borg
-
+
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
-
+
http://www.apache.org/licenses/LICENSE-2.0
-
+
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
*/
@@ -16,9 +16,9 @@ Unless required by applicable law or agreed to in writing, software distributed
@class CTGradient;
@interface SMLStatusBarTextFieldCell : NSTextFieldCell {
-
+
NSMutableDictionary *attributes;
-
+
CTGradient *statusBarGradient;
}
View
10 Headers/app/TabletEvents.h
@@ -39,16 +39,16 @@ All rights reserved.
///////////////////////////////////////////////////////////////////////////
/* This is the name of the Notification sent when a proximity event is
captured by the application */
-extern NSString *kProximityNotification;
+extern NSString *kProximityNotification;
/* vendor-defined ID - typically will be USB vendor ID */
-extern NSString *kVendorID;
+extern NSString *kVendorID;
/* vendor-defined tablet ID */
extern NSString *kTabletID;
/* vendor-defined ID of the specific pointing device */
-extern NSString *kPointerID;
+extern NSString *kPointerID;
/* unique device ID - matches to deviceID field in tablet event */
extern NSString *kDeviceID;
@@ -57,7 +57,7 @@ extern NSString *kDeviceID;
extern NSString *kSystemTabletID;
/* vendor-defined pointer type */
-extern NSString *kVendorPointerType;
+extern NSString *kVendorPointerType;
/* vendor-defined serial number of the specific pointing device */
extern NSString *kPointerSerialNumber;
@@ -72,4 +72,4 @@ extern NSString *kCapabilityMask;
extern NSString *kPointerType;
/* non-zero = entering; zero = leaving */
-extern NSString *kEnterProximity;
+extern NSString *kEnterProximity;
View
2  Headers/app/UserPanel.h
@@ -34,7 +34,7 @@
- (void)windowWillClose:(NSNotification *)aNotification;
- (void)setSCObject: (struct PyrObject*)inObject;
- (struct PyrObject*) getSCObject;
-
+
- (IBAction) panelAction: (id) sender;
@end
View
120 Headers/app/iPhone/iPhoneSCView.h
@@ -69,7 +69,7 @@ struct SCViewMaker
{
SCViewMaker(const char* inName, SCViewCtor inCtor);
static SCView* MakeSCView(PyrObject* inObj, SCContainerView *inParent, SCRect inBounds, const char* classname);
-
+
SCViewMaker *mNext;
SCViewCtor mCtor;
const char* mName;
@@ -81,9 +81,9 @@ extern SCView *gAnimatedViews;
class SCView
{
public:
- SCView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCView();
-
+
virtual void draw(SCRect inDamage);
virtual void drawFocus(SCRect inDamage);
virtual void drawDisabled(SCRect inDamage);
@@ -105,22 +105,22 @@ class SCView
void setConstructionModeFromPoint(SCPoint where);
virtual bool shouldDim();
void beginDrag(SCPoint where);
-
+
virtual bool canReceiveDrag();
virtual void receiveDrag();
-
+
bool isFocus() const;
bool hit(SCPoint p) const;
void refresh();
virtual void refreshInRect(SCRect b);
void refreshFocus();
void setDragHilite(bool inFlag);
-
+
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
-
+
virtual void setVisibleFromParent() { } // does nothing, needed for Cocoa views
-
+
virtual bool isDragSource() const;
virtual SCView* findView(SCPoint where);
virtual SCView* findViewByID(int32 inID);
@@ -138,29 +138,29 @@ class SCView
virtual Layout getLayout();
// virtual void setLayout(Layout inLayout);
-
+
SCView* next() { return mNext; }
SCContainerView* parent() { return mParent; }
-
+
//virtual NSMenu* contextMenu(SCPoint inPoint);
-
+
virtual void setMenuItemChosen(int inItem) {}
-
+
PyrObject* GetSCObj() { return mObj; }
SCView* NextAnimatedView() const { return mNextAnimatedView; }
-
+
void startAnimation();
void stopAnimation();
virtual void animate() { refresh(); }
-
+
virtual bool isScroller() { return false; }
virtual bool isSubViewScroller() { return false; }
virtual bool isContainer() { return false; }
virtual SCRect checkMinimumSize() { return mBounds; }
virtual bool relativeOrigin() {return false;}
-
+
bool isTopContainer(){ return (!mParent);};
-
+
protected:
friend class SCContainerView;
friend class SCScrollView;
@@ -190,11 +190,11 @@ class SCView
class SCContainerView : public SCView
{
public:
- SCContainerView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCContainerView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCContainerView();
-
+
virtual void drawIfNecessary(SCRect inDamage);
-
+
virtual void add(SCView *inChild);
virtual void remove(SCView *inChild);
virtual SCView* findView(SCPoint where);
@@ -209,17 +209,17 @@ class SCContainerView : public SCView
virtual bool isVisible() {return mVisible && mParent->isVisible(); }
virtual bool relativeOrigin() {return mRelativeOrigin;}
virtual bool isContainer() { return true; }
-
+
protected:
SCView *mChildren;
int mNumChildren;
- bool mRelativeOrigin;
+ bool mRelativeOrigin;
};
class SCCompositeView : public SCContainerView
{
public:
- SCCompositeView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCCompositeView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCCompositeView();
virtual void setBounds(SCRect inBounds);
@@ -229,9 +229,9 @@ class SCCompositeView : public SCContainerView
class SCLayoutView : public SCContainerView
{
public:
- SCLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCLayoutView();
-
+
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual void add(SCView *inChild);
@@ -243,18 +243,18 @@ class SCLayoutView : public SCContainerView
class SCHLayoutView : public SCLayoutView
{
public:
- SCHLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCHLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCHLayoutView();
virtual void setBounds(SCRect inBounds);
-
+
protected:
};
class SCVLayoutView : public SCLayoutView
{
public:
- SCVLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+ SCVLayoutView(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCVLayoutView();
virtual void setBounds(SCRect inBounds);
@@ -270,12 +270,12 @@ class SCTopView : public SCCompositeView
{
public:
SCTopView(PyrObject* inObj, SCRect inBounds);
-
- SCView *focusView() {
+
+ SCView *focusView() {
if(isSubViewScroller()) {
return mTop->focusView();
} else {
- return mFocusView;
+ return mFocusView;
}
}
@@ -284,34 +284,34 @@ class SCTopView : public SCCompositeView
void resetFocus();
void addDamage(SCRect inRect);
void beginDragCallback(SCPoint where, PyrSlot* slot, NSString* string, NSString* label);
-
+
void setDamageCallback(DamageCallback inFunc, void *inHostData)
{ mDamageCallback = inFunc; mHostData = inHostData; }
void setDragCallback(DragCallback inFunc)
{ mDragCallback = inFunc; }
-
+
void tabNextFocus();
void tabPrevFocus();
void setDragView(SCView *inView);
-
+
UIView* GetUIView() { return mUIView; }
void SetUIView(UIView* inView) { mUIView = inView; }
bool ConstructionMode() { return mConstructionMode; }
void SetConstructionMode(bool inFlag) { mConstructionMode = inFlag; }
-
+
virtual void drawFocus(SCRect inDamage);
- virtual bool canReceiveDrag();
+ virtual bool canReceiveDrag();
virtual void receiveDrag();
virtual void setInternalBounds(SCRect internalBounds);
virtual bool isVisible() {return mVisible; }
protected:
friend class SCView;
- void focusIs(SCView *inView) {
+ void focusIs(SCView *inView) {
if(isSubViewScroller()) {
mTop->focusIs(inView);
} else {
- mFocusView = inView;
+ mFocusView = inView;
}
}
@@ -321,7 +321,7 @@ class SCTopView : public SCCompositeView
SCView *mFocusView;
SCView *mDragView;
UIView *mUIView;
-
+
bool mConstructionMode;
};
@@ -334,12 +334,12 @@ class SCScrollTopView : public SCTopView
{
public:
SCScrollTopView(PyrObject* inObj, SCRect inBounds);
-
+
UIScrollView* GetScrollView() { return mUIScrollView; }
void SetUIScrollView(UIScrollView* inView) { mUIScrollView = inView; }
-
+
virtual bool isScroller() { return true; }
-
+
virtual SCRect getDrawBounds();
virtual void setInternalBounds(SCRect inBounds);
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
@@ -349,7 +349,7 @@ class SCScrollTopView : public SCTopView
virtual void remove(SCView *inChild);
bool isInSetClipViewOrigin() { return mInSetClipViewOrigin; }
void setInSetClipViewOrigin(bool flag) { mInSetClipViewOrigin = flag; }
-
+
protected:
UIScrollView *mUIScrollView;
bool mInSetClipViewOrigin;
@@ -363,14 +363,14 @@ class SCScrollView : public SCScrollTopView
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual void setVisibleFromParent();
//virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
-
+
virtual void setBounds(SCRect inBounds);
virtual SCRect getBounds();
virtual void add(SCView *inChild);
// virtual void remove(SCView *inChild);
-
+
virtual bool isSubViewScroller() { return true; }
-
+
virtual void drawIfNecessary(SCRect inDamage);
virtual void drawSubViewIfNecessary(SCRect inDamage);
virtual bool isVisible() {return mVisible && mParent->isVisible(); }
@@ -381,12 +381,12 @@ inline bool SCView::isFocus() const { return mTop->focusView() == this; }
class SCSlider : public SCView
{
-public:
- SCSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCSlider(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual void draw(SCRect inDamage);
virtual void touchTrack(SCPoint where, UITouch *touch);
-
+
double value() { return mValue; }
bool setValue(double inValue, bool send);
@@ -399,7 +399,7 @@ class SCSlider : public SCView
protected:
virtual void setValueFromPoint(SCPoint point);
void calcThumbRect(SCRect bounds);
-
+
SCRect mThumbRect;
double mValue, mStepSize, mStepScale;
DrawBackground* mKnob;
@@ -420,8 +420,8 @@ const int kFontNameSize = 80;
class SCButton : public SCView
{
-public:
- SCButton(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCButton(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCButton();
virtual void draw(SCRect inDamage);
@@ -437,7 +437,7 @@ class SCButton : public SCView
virtual void receiveDrag();
protected:
-
+
int mValue;
char mFontName[kFontNameSize];
float mFontSize;
@@ -455,16 +455,16 @@ enum {
class SCStaticText : public SCView
{
-public:
- SCStaticText(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCStaticText(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCStaticText();
-
+
virtual void draw(SCRect inDamage);
virtual bool shouldDim();
virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
-
+
protected:
virtual void drawString(SCRect bounds);
@@ -479,16 +479,16 @@ SCView* NewSCStaticText(SCContainerView *inParent, PyrObject* inObj, SCRect inBo
class SCNumberBox : public SCStaticText
{
-public:
- SCNumberBox(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
+public:
+ SCNumberBox(SCContainerView *inParent, PyrObject* inObj, SCRect inBounds);
virtual ~SCNumberBox();
-
+
virtual void draw(SCRect inDamage);
virtual bool shouldDim();
virtual void touchTrack(SCPoint where, UITouch *touch);
//virtual void mouseEndTrack(SCPoint where, int modifiers);
-
+
//virtual int setProperty(PyrSymbol *symbol, PyrSlot *slot);
//virtual int getProperty(PyrSymbol *symbol, PyrSlot *slot);
View
98 Headers/common/SC_AllocPool.h
@@ -58,42 +58,42 @@ class AllocChunk : public Link<AllocChunk>
{
friend class AllocPool;
- size_t Size()
+ size_t Size()
{ return mSize & kSizeBits; }
-
- size_t PrevSize()
+
+ size_t PrevSize()
{ return mPrevSize & kSizeBits; }
-
- AllocChunkPtr ChunkAtOffset(long inSize)
+
+ AllocChunkPtr ChunkAtOffset(long inSize)
{ return AllocChunkPtr((char*)this + inSize); }
-
- AllocChunkPtr NextChunk()
+
+ AllocChunkPtr NextChunk()
{ return ChunkAtOffset(Size()); }
-
- AllocChunkPtr PrevChunk()
+
+ AllocChunkPtr PrevChunk()
{ return ChunkAtOffset(-(long)PrevSize()); }
-
- bool InUse()
+
+ bool InUse()
{ return (bool)(mSize & kChunkInUse); }
-
- bool PrevInUse()
+
+ bool PrevInUse()
{ return (bool)(mPrevSize & kChunkInUse); }
-
- void SetSizeFree(size_t inSize)
+
+ void SetSizeFree(size_t inSize)
{ mSize = ChunkAtOffset(inSize)->mPrevSize = inSize; }
-
- void SetSizeInUse(size_t inSize)
+
+ void SetSizeInUse(size_t inSize)
{ mSize = ChunkAtOffset(inSize)->mPrevSize = inSize | kChunkInUse; }
-
+
void SetNeighborsInUse(size_t inOffset)
{ mPrevSize = ChunkAtOffset(inOffset)->mSize = kChunkInUse; }
-
+
bool IsArea()
{ return mPrevSize == kChunkInUse && NextChunk()->mSize == kChunkInUse; }
-
- void* ToPtr()
+
+ void* ToPtr()
{ return (void*)((char*)this + sizeof(AllocChunk)); }
-
+
size_t mPrevSize;
size_t mSize;
};
@@ -105,20 +105,20 @@ class AllocAreaHdr /* for size calculations */
{
protected:
friend class AllocPool;
-
+
AllocAreaPtr mPrev, mNext;
size_t mSize;
void *mUnalignedPointerToThis;
-};
+};
class AllocArea : public AllocAreaHdr
{
public:
void SanityCheck();
-
+
private:
friend class AllocPool;
-
+
AllocChunk mChunk;
};
@@ -129,37 +129,37 @@ const size_t kAreaOverhead = sizeof(AllocAreaHdr) + 2 * sizeof(AllocChunk);
typedef void* (*NewAreaFunc)(size_t size);
typedef void (*FreeAreaFunc)(void *);
-class AllocPool