*/}}

la_interface.h 63 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103110411051106110711081109111011111112111311141115111611171118111911201121112211231124112511261127112811291130113111321133113411351136113711381139114011411142114311441145114611471148114911501151115211531154115511561157115811591160116111621163116411651166116711681169117011711172117311741175117611771178117911801181118211831184118511861187118811891190119111921193119411951196119711981199120012011202120312041205120612071208120912101211121212131214121512161217121812191220122112221223122412251226122712281229123012311232123312341235123612371238123912401241124212431244124512461247124812491250125112521253125412551256125712581259126012611262126312641265126612671268126912701271127212731274127512761277127812791280128112821283128412851286128712881289129012911292129312941295129612971298129913001301130213031304130513061307130813091310131113121313131413151316131713181319132013211322132313241325132613271328132913301331133213331334133513361337133813391340134113421343134413451346134713481349135013511352135313541355135613571358135913601361136213631364136513661367136813691370137113721373137413751376137713781379138013811382138313841385138613871388138913901391139213931394139513961397139813991400140114021403140414051406140714081409141014111412141314141415141614171418141914201421142214231424142514261427142814291430143114321433143414351436143714381439144014411442144314441445144614471448144914501451145214531454145514561457145814591460146114621463146414651466146714681469147014711472147314741475147614771478147914801481148214831484148514861487148814891490149114921493149414951496149714981499150015011502150315041505150615071508150915101511151215131514151515161517151815191520152115221523152415251526152715281529153015311532153315341535153615371538153915401541154215431544154515461547154815491550155115521553155415551556155715581559156015611562156315641565156615671568156915701571157215731574157515761577157815791580158115821583158415851586158715881589159015911592159315941595159615971598159916001601160216031604160516061607160816091610161116121613161416151616161716181619162016211622162316241625162616271628162916301631163216331634163516361637163816391640164116421643164416451646164716481649165016511652165316541655165616571658165916601661166216631664166516661667166816691670167116721673167416751676167716781679168016811682168316841685168616871688168916901691169216931694169516961697169816991700170117021703170417051706170717081709171017111712171317141715171617171718171917201721172217231724172517261727172817291730173117321733173417351736173717381739174017411742174317441745174617471748174917501751175217531754175517561757175817591760176117621763176417651766176717681769177017711772177317741775177617771778177917801781178217831784178517861787178817891790179117921793179417951796179717981799180018011802180318041805180618071808180918101811181218131814181518161817181818191820182118221823182418251826182718281829183018311832183318341835183618371838183918401841184218431844184518461847184818491850185118521853185418551856185718581859186018611862186318641865186618671868186918701871187218731874187518761877187818791880188118821883188418851886188718881889189018911892189318941895189618971898189919001901190219031904190519061907190819091910191119121913191419151916191719181919192019211922192319241925192619271928192919301931193219331934193519361937193819391940194119421943194419451946194719481949195019511952195319541955195619571958195919601961196219631964196519661967
  1. #pragma once
  2. #include <X11/Xlib.h>
  3. #include <X11/Xutil.h>
  4. #include <X11/Xresource.h>
  5. #include <X11/Xlocale.h>
  6. #include <X11/XKBlib.h>
  7. #include <GL/glew.h>
  8. //#include <GL/glxew.h>
  9. #include <GL/gl.h>
  10. #include <GL/glx.h>
  11. #include <GL/glext.h>
  12. #include <GL/glu.h>
  13. #include "la_5.h"
  14. #include "la_data.h"
  15. //#include "llvm-c/Analysis.h"
  16. //#include "llvm-c/BitWriter.h"
  17. //#include "llvm-c/Core.h"
  18. //#include "llvm-c/ExecutionEngine.h"
  19. //#include "llvm-c/Target.h"
  20. //#include <Windows.h>
  21. #define LA_VERSION_MAIN 5
  22. #define LA_VERSION_SUB 0
  23. #define LA_VERSION_MINOR 0
  24. #define LA_UDF_CAPABILITY_MAIN 5
  25. #define LA_UDF_CAPABILITY_SUB 0
  26. #define LA_UDF_CAPABILITY_MINOR 0
  27. #define LA_ACTUATOR_CAPABILITY_MAIN 5
  28. #define LA_ACTUATOR_CAPABILITY_SUB 0
  29. #define LA_ACTUATOR_CAPABILITY_MINOR 0
  30. #define LA_NODE_MAIN_MODULE_NAME "LA_NODE_MAIN_MODULE"
  31. #define LA_GUI_WNDCLASS_NAME "LA_WINDOW_CLASS"
  32. #define LA_ARROW 1
  33. #define LA_CROSS 2
  34. #define LA_LEFT_RIGHT 3
  35. #define LA_UP_AND_DOWN 4
  36. #define LA_HAND 5
  37. #define LA_MOVE 6
  38. #define EVT_WND_MOVE -1
  39. #define EVT_WND_SIZE_BEGIN -2
  40. #define EVT_WND_SIZE_FINISH -3
  41. #define EVT_WND_SIZE -4
  42. #define EVT_WND_SHOW -5
  43. #define EVT_FEEDBACK 8192
  44. #define LA_KEYBOARD_EVENT (1<<0)
  45. #define LA_MOUSE_EVENT (1<<1)
  46. #define LA_STATE_MOVE (1<<2)
  47. #define LA_STATE_DOWN (1<<3)
  48. #define LA_STATE_UP (1<<4)
  49. #define LA_TIME_EVENT (1<<5)
  50. #define LA_TIME_IDLE (LA_TIME_EVENT|(1<<6))
  51. #define LA_TIME_DELAY (LA_TIME_EVENT|(1<<7))
  52. #define LA_KEY_MOUSE_LEFT (1<<8)
  53. #define LA_KEY_MOUSE_MIDDLE (1<<9)
  54. #define LA_KEY_MOUSE_RIGHT (1<<10)
  55. #define LA_KEY_MOUSE_SCROLL (1<<11)
  56. #define LA_KEY_BACKSPACE (1<<12)
  57. #define LA_KEY_ESCAPE (1<<13)
  58. #define LA_KEY_ENTER (1<<14)
  59. #define LA_INPUT (1<<15)
  60. #define LA_KEY_ARRLEFT (1<<16)
  61. #define LA_KEY_ARRRIGHT (1<<17)
  62. #define LA_KEY_ARRUP (1<<18)
  63. #define LA_KEY_ARRDOWN (1<<19)
  64. #define LA_KEY_SHIFT (1<<20)
  65. #define LA_KEY_CTRL (1<<21)
  66. #define LA_KEY_ALT (1<<22)
  67. #define LA_KEY_DELETE (1<<23)
  68. #define LA_KEY_TAB (1<<24)
  69. #define LA_KEY_SPECIALS (LA_KEY_CTRL|LA_KEY_SHIFT|LA_KEY_ALT)
  70. #define LA_MOUSEMOVE (LA_MOUSE_EVENT | LA_STATE_MOVE)
  71. #define LA_EMPTY LA_MOUSEMOVE
  72. #define LA_MOUSEDOWN (LA_MOUSE_EVENT | LA_STATE_DOWN)
  73. #define LA_MOUSEUP (LA_MOUSE_EVENT | LA_STATE_UP)
  74. #define LA_WHEEL (LA_MOUSE_EVENT | LA_KEY_MOUSE_SCROLL)
  75. #define LA_L_MOUSE_DOWN (LA_MOUSE_EVENT | LA_STATE_DOWN | LA_KEY_MOUSE_LEFT)
  76. #define LA_L_MOUSE_UP (LA_MOUSE_EVENT | LA_STATE_UP | LA_KEY_MOUSE_LEFT)
  77. #define LA_M_MOUSE_DOWN (LA_MOUSE_EVENT | LA_STATE_DOWN | LA_KEY_MOUSE_MIDDLE)
  78. #define LA_M_MOUSE_UP (LA_MOUSE_EVENT | LA_STATE_UP | LA_KEY_MOUSE_MIDDLE)
  79. #define LA_R_MOUSE_DOWN (LA_MOUSE_EVENT | LA_STATE_DOWN | LA_KEY_MOUSE_RIGHT)
  80. #define LA_R_MOUSE_UP (LA_MOUSE_EVENT | LA_STATE_UP | LA_KEY_MOUSE_RIGHT)
  81. #define LA_MOUSE_WHEEL_DOWN (LA_MOUSE_EVENT | LA_STATE_DOWN | LA_KEY_MOUSE_SCROLL)
  82. #define LA_MOUSE_WHEEL_UP (LA_MOUSE_EVENT | LA_STATE_UP | LA_KEY_MOUSE_SCROLL)
  83. #define LA_KEY_DOWN (LA_KEYBOARD_EVENT | LA_STATE_DOWN)
  84. #define LA_KEY_UP (LA_KEYBOARD_EVENT | LA_STATE_UP)
  85. #define LA_LEFT_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ARRLEFT | LA_STATE_DOWN)
  86. #define LA_RIGHT_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ARRRIGHT | LA_STATE_DOWN)
  87. #define LA_UP_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ARRUP | LA_STATE_DOWN)
  88. #define LA_DOWN_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ARRDOWN | LA_STATE_DOWN)
  89. #define LA_LEFT_UP (LA_KEYBOARD_EVENT | LA_KEY_ARRLEFT | LA_STATE_UP)
  90. #define LA_RIGHT_UP (LA_KEYBOARD_EVENT | LA_KEY_ARRRIGHT | LA_STATE_UP)
  91. #define LA_UP_UP (LA_KEYBOARD_EVENT | LA_KEY_ARRUP | LA_STATE_UP)
  92. #define LA_DOWN_UP (LA_KEYBOARD_EVENT | LA_KEY_ARRDOWN | LA_STATE_UP)
  93. #define LA_BACKSPACE_DOWN (LA_KEYBOARD_EVENT | LA_KEY_BACKSPACE | LA_STATE_DOWN)
  94. #define LA_BACKSPACE_UP (LA_KEYBOARD_EVENT | LA_KEY_BACKSPACE | LA_STATE_UP)
  95. #define LA_ESCAPE_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ESCAPE | LA_STATE_DOWN)
  96. #define LA_ESCAPE_UP (LA_KEYBOARD_EVENT | LA_KEY_ESCAPE | LA_STATE_UP)
  97. #define LA_ENTER_DOWN (LA_KEYBOARD_EVENT | LA_KEY_ENTER | LA_STATE_DOWN)
  98. #define LA_ENTER_UP (LA_KEYBOARD_EVENT | LA_KEY_ENTER | LA_STATE_UP)
  99. #define LA_ONLY_BITS_AND(orig, yours) \
  100. ((orig & yours) == yours)
  101. NEED_STRUCTURE(laTunnel);
  102. NEED_STRUCTURE(laUiList);
  103. NEED_STRUCTURE(laUiItem);
  104. NEED_STRUCTURE(laColumn);
  105. typedef void (*laUiDrawFunc)(void *, int); //Instance,Theme
  106. typedef void (*laPanelDrawFunc)(void *, void *, void *); //Window,Instance,Theme
  107. //typedef void(*laUiDefineFunc)(laUiList*,laPropPack*,laPropPack*,laColumn*);//uil,collection inst+"This" inst,actuator inst,Extra column list.
  108. typedef void (*laOperatorArgumentParserFunc)(laStringSplitor *, uint32_t *, char *); //icon id,display string buf
  109. typedef int (*laUiGetHeightFunc)(laUiItem *);
  110. typedef int (*laUiGetMinWidthFunc)(laUiItem *);
  111. typedef int (*laUiConditionFunc)(laPropPack *); //maybe inst+actuator,replaceInst
  112. typedef void (*laUiDestroyFunc)(laUiItem *);
  113. typedef void (*laUiInitFunc)(laUiItem *);
  114. typedef void (*laUiRefreshFunc)(laUiItem *);
  115. typedef void (*laLayoutBkgDrawFunc)(void *, void *l);
  116. typedef void (*laPreFrameF)();
  117. typedef void (*laPreDrawF)();
  118. typedef void (*laPostFrameF)();
  119. typedef void (*laCleanupF)();
  120. STRUCTURE(laEvent){
  121. laListItem Item;
  122. int Type;
  123. int state;
  124. int x, y;
  125. int key;
  126. int SpecialKeyBit;
  127. int p1, p2;
  128. uint32_t Input;
  129. int IsEraser;
  130. real Pressure,AngleX,AngleY;
  131. void *Localized;
  132. //void* BoardcastedData;
  133. };
  134. NEED_STRUCTURE(laWindow)
  135. NEED_STRUCTURE(laRoot)
  136. NEED_STRUCTURE(laPanel)
  137. NEED_STRUCTURE(laUiItem)
  138. NEED_STRUCTURE(laUiList)
  139. NEED_STRUCTURE(laAnimationAction)
  140. NEED_STRUCTURE(laUiDescriptor)
  141. NEED_STRUCTURE(laUiConditionNode)
  142. STRUCTURE(laSharedTypeItem){
  143. laListItem Item;
  144. char ID[64];
  145. void *Pointer;
  146. };
  147. #define LA_ANIMATION_STOPPED 0
  148. #define LA_ANIMATION_PLAYING 1
  149. #define LA_ANIMATION_PLAYING_REVERSE 2
  150. STRUCTURE(laAnimationGlobal){
  151. laListItem Item;
  152. int PlayStatus;
  153. int Frame;
  154. int FrameBegin, FrameEnd;
  155. int FrameStep;
  156. int FrameRate;
  157. };
  158. NEED_STRUCTURE(laTranslation);
  159. NEED_STRUCTURE(laTheme);
  160. STRUCTURE(laKeyMapper){
  161. laListItem Item;//unused;
  162. laListHandle Items;
  163. };
  164. STRUCTURE(laLogEntry){
  165. laListItem Item;
  166. laSafeString* Content;
  167. int Type;
  168. };
  169. NEED_STRUCTURE(laManagedUDF);
  170. STRUCTURE(laNodeOutSocket){
  171. void* Parent;
  172. void* Data;
  173. laSafeString* Label;
  174. int DataType, ArrLen;
  175. int RuntimeX, RuntimeY, RuntimePX, RuntimePY;
  176. };
  177. STRUCTURE(laNodeInSocket){
  178. laNodeOutSocket* Source;
  179. laSafeString* Label;
  180. int DataType, ArrLen; int ColorId;
  181. int RuntimeX, RuntimeY, RuntimePX, RuntimePY;
  182. };
  183. NEED_STRUCTURE(laBaseNodeType);
  184. NEED_STRUCTURE(laRackPage);
  185. NEED_STRUCTURE(laNodeCategory);
  186. STRUCTURE(laRackPageCollection){
  187. laRackPage* CurrentPage;
  188. laListHandle Pages;
  189. laListHandle Eval;
  190. int NeedEval,NeedRebuild;
  191. };
  192. typedef laBaseNodeType* (*laGetBaseNodeTypeF)(char* str);
  193. STRUCTURE(LA){
  194. laListItem Hyper;
  195. laListHandle Logs;
  196. laListHandle Controllers; int NextControllerID;
  197. laListHandle Windows;
  198. laListHandle WastedPanels;
  199. laPreFrameF PreFrame;
  200. laPreDrawF PreDraw;
  201. laPostFrameF PostFrame;
  202. laCleanupF Cleanup;
  203. real IdleStart, DelayStart;
  204. int DelayTriggered;
  205. int IdleTriggered;
  206. int ReTriggerOperators;
  207. laPanel* DockingPanel;
  208. char *InputBuf; int InputBufNext, InputBufMax;
  209. int32_t *InputBufU; int InputBufUNext, InputBufUMax;
  210. Atom MsgDelWindow;
  211. Atom bufid;
  212. Atom fmtid;
  213. Atom propid;
  214. Atom incrid;
  215. Atom targets_atom;
  216. Atom text_atom;
  217. Atom UTF8;
  218. Atom selection;
  219. laSafeString* CopyPending;
  220. Display* dpy;
  221. XVisualInfo* xvi;
  222. GLXFBConfig BestFBC;
  223. GLXContext glc;
  224. Colormap cmap;
  225. XIM im;
  226. XIC ic;
  227. int xi_opcode;
  228. int WacomDeviceStylus; real StylusPressure, StylusAngleX, StylusAngleY;
  229. int WacomDeviceEraser; real EraserPressure, EraserAngleX, EraserAngleY;
  230. int PointerIsEraser;
  231. laWindow *CurrentWindow;
  232. laPanel *CurrentPanel;
  233. int InitDone;
  234. int SpecialKeyStates;
  235. laKeyMapper KeyMap;
  236. laHash256 OperatorTypeHash;
  237. laPropContainer *GeneralIntSub;
  238. laPropContainer *GeneralFloatSub;
  239. laPropContainer *GeneralEnumSub;
  240. laPropContainer *GeneralIntArraySub;
  241. laPropContainer *GeneralFloatArraySub;
  242. laPropContainer *GeneralEnumArraySub;
  243. laPropContainer *GeneralStringSub;
  244. laPropContainer *GeneralOperatorSub;
  245. laPropContainer *GeneralCollectionSub;
  246. laPropContainer *GeneralRawSub;
  247. laPropContainer *ContainerInt;
  248. laPropContainer *ContainerFloat;
  249. laPropContainer *ContainerEnum;
  250. laPropContainer *ContainerString;
  251. laPropContainer *ContainerOperator;
  252. laPropContainer *ContainerCollection;
  253. laListHandle PropContainers;
  254. laRoot DataRoot;
  255. laPanel *PropMatcherContextP;
  256. laAnimationGlobal Animation;
  257. laTheme* CurrentTheme;
  258. laListHandle Themes;
  259. laListHandle UiTypes;
  260. laListHandle InitPanelTemplates;
  261. laListHandle PanelTemplates;
  262. laListHandle View2DTemplates;
  263. laUiDefineFunc MenuButtons;
  264. laUiDefineFunc MenuExtras;
  265. const char* MenuProgramName;
  266. laHash256 GlobalMemPool;
  267. int ByteCount;
  268. int TotalByteCount;
  269. laHash65536* DBInstMemLeft;// list item pointers
  270. laHash16M DBInst2;
  271. laHash16M DBInst1;
  272. laHash16M PtrSync;
  273. laListHandle PtrSyncAddressCommands;
  274. laListHandle PtrSyncHyper2Commands;
  275. laListHandle PostReadNodes;
  276. laListHandle RenewHyper2s;
  277. laListHandle SharedTypePointerSync;
  278. laListHandle PendingResourceRequests;
  279. laListHandle ResourceFolders;
  280. laListHandle ResourceRegistries;
  281. laListHandle UDFResources;
  282. laListHandle ManagedUDFs;
  283. laListHandle ManagedSaveProps;
  284. laManagedUDF* DummyManageUDF;
  285. int ManagerDefaultView;
  286. laListHandle DBInstPendingAcquireDBP;
  287. laListHandle DBInstPendingAcquireDiffCMD;
  288. laListHandle DiffTouched;
  289. laListHandle Differences;
  290. laDiff* HeadDifference;
  291. laDBInst RootDBInst;
  292. laListHandle DBRecordedProps;
  293. laHash65536* DBInstLink;
  294. real FontSize;
  295. real MarginSize;
  296. int UiRowHeight;
  297. int ScaledUiRowHeight;
  298. real UiScale;
  299. void *ToPanel;
  300. int NextX, NextY, NextW, NextH;
  301. laNodeInSocket tNodeIn;
  302. laNodeOutSocket tNodeOut;
  303. laAuthorInfo Author;
  304. laListHandle ExternalAuthors;
  305. laSafeString *WorkingDirectory;
  306. //pthread_spinlock_t csNotifier;
  307. laListHandle ThreadNotifiers;
  308. //preference:
  309. //color
  310. int ColorAccessCorrectGamma;
  311. real Gamma;
  312. int NextWireColor, WireColorSlices;
  313. real WireThickness;
  314. real WireSaggyness;
  315. real* WireColorCache;
  316. //user interactions:
  317. int TopFramerate;
  318. int ValuatorThreshold;
  319. int ScrollingSpeed;
  320. int TooltipCloseDistance;
  321. real ZoomSpeed2D;
  322. real IdleTime;
  323. real DelayTime;
  324. //translations:
  325. laTranslation Translation;
  326. //display:
  327. real FloatingAlpha;
  328. int SolidShadowLength;
  329. int EnableAnimation;
  330. real AnimationSpeed;
  331. real PanelAnimationSpeed;
  332. int PanelMultisample;
  333. real LastFrameTime;
  334. real TimeAccum;
  335. //animation:
  336. int DefaultKeyFrameMode;
  337. //laThemeColor *ConditionStackColors[6];
  338. laUDFContentNode TEST_Link;
  339. laListHandle MediaFiles;
  340. laRackPageCollection* InputMapping;
  341. laRackPageCollection* Drivers;
  342. laListHandle NodeCategories;
  343. laNodeCategory* CurrentNodeCategory;
  344. int FilterNodeCategory;
  345. laBaseNodeType** NodeTypes; int NodeTypeNext, NodeTypeMax;
  346. laUiDefineFunc ExtraAddInputNodes;
  347. laUiDefineFunc ExtraAddDriverNodes;
  348. laGetBaseNodeTypeF ExtraGetInputNodeType;
  349. laGetBaseNodeTypeF ExtraGetDriverNodeType;
  350. //laHash256 RootNodes;
  351. //LLVMContextRef llvmContext;
  352. //LLVMModuleRef llvmModule;
  353. //pthread_spinlock_t csMediaPlay;
  354. int example_int;
  355. laSafeString* example_string;
  356. };
  357. #define LA_KM_SEL_UI_EXTRA 1
  358. #define LA_KM_SEL_PANEL 2
  359. STRUCTURE(laKeyMapItem){
  360. laListItem Item;
  361. int SpecialKeyBits;
  362. int EventType;
  363. int Key;
  364. char SelectBase;
  365. laPropPack Base;
  366. laPropPack Action;
  367. laSafeString *Operation;
  368. laSafeString *Instructions;
  369. };
  370. NEED_STRUCTURE(laLayout);
  371. NEED_STRUCTURE(laBlock);
  372. NEED_STRUCTURE(laPanel);
  373. NEED_STRUCTURE(laUiItem);
  374. STRUCTURE(laWindow){
  375. laListItem Item;
  376. Window* win;
  377. GLXContext glc;
  378. int X;
  379. int Y;
  380. int W;
  381. int H;
  382. int CW;
  383. int CH;
  384. laPropPack PP;
  385. laPropStep FakePS;
  386. laSafeString *Title;
  387. int Activated;
  388. int Shown;
  389. int IsDocking;
  390. laWindow* DockingFrom;
  391. laListHandle EventList;
  392. laSafeString *OperatorHints;
  393. laListHandle Layouts;
  394. laLayout *CurrentLayout;
  395. laBlock *MaximizedBlock;
  396. laPanel *MaximizedUiPanel;
  397. laUiItem *MaximizedUi;
  398. laListHandle Panels;
  399. laListHandle FadingPanels;
  400. laListHandle Operators;
  401. laListHandle PendingOperators;
  402. laUiDrawFunc Draw;
  403. };
  404. STRUCTURE(laBlock){
  405. int X, Y, W, H;
  406. laBlock *B1;
  407. laBlock *B2;
  408. laBlock *parent;
  409. laPanel *CurrentPanel;
  410. laListHandle Panels;
  411. int Vertical;
  412. int Folded;
  413. real SplitRatio; // From Left/Top;
  414. laPropPack PP;
  415. laPropPack FakePS;
  416. int OnButton;
  417. };
  418. #define LA_BLOCK_DROP_LOCATION_L 1
  419. #define LA_BLOCK_DROP_LOCATION_R 2
  420. #define LA_BLOCK_DROP_LOCATION_U 3
  421. #define LA_BLOCK_DROP_LOCATION_B 4
  422. STRUCTURE(laLayout){
  423. laListItem Item;
  424. laBlock *OperatingBlock;
  425. laBlock *FirstBlock;
  426. laBlock *MovingBlock;
  427. int IsMoving;
  428. laPanel *ClickedPanel;
  429. laBlock *DropToBlock;
  430. laBlock *OnBlockSeperator;
  431. char DropLocation;
  432. laSafeString *ID;
  433. laLayoutBkgDrawFunc Draw;
  434. };
  435. STRUCTURE(laUiList){
  436. laListItem Item;
  437. int L, R, U, B;
  438. int TL, TR, TU, TB;
  439. real PanX, PanY; //Pan Up/Left Is Positive
  440. laListHandle UiItems;
  441. laListHandle Columns;
  442. laListHandle *ShareColumns;
  443. laSafeString *TabName;
  444. char *Instance;
  445. short HeightCoeff;
  446. char ScrollerShownV;
  447. char ScrollerShownH;
  448. uint32_t IconID;
  449. int AllowScale;
  450. real Scale; real SaveScale;
  451. };
  452. STRUCTURE(laUiListRecord){
  453. laListItem Item;
  454. laUiList* uil;
  455. laUiItem* pui;
  456. };
  457. STRUCTURE(laColumn){
  458. laListItem Item;
  459. real PreWidth;
  460. real SP;
  461. int IL, IR;
  462. laColumn *Top;
  463. int MaxW;
  464. int B;
  465. laColumn *LS, *RS;
  466. laColumn *CopyRef;
  467. };
  468. STRUCTURE(laUiListDraw){
  469. laListHandle Items;
  470. laListHandle SocketRecord;
  471. laUiList* WiresContainer;
  472. };
  473. STRUCTURE(laUiListDrawItem){
  474. laListItem Item;
  475. laUiList *Target;
  476. int L, R, U, B, XP, YP, DifX, DifY;
  477. int ExtraPanX;
  478. real Scale;
  479. };
  480. STRUCTURE(laBoxedTheme){
  481. laListItem Item;
  482. laSafeString *Name;
  483. real NormalY, Normal[4], Inactive[4];
  484. real ActiveY, Active[4];
  485. real BorderY, Border[4];
  486. real TextY, Text[4];
  487. real TextActiveY, TextActive[4], TextInactive[4];
  488. real Alpha;
  489. int TextAlign;
  490. real Margins[4];
  491. real Paddings[4];
  492. //Don't change order
  493. int LM, RM, TM, BM;
  494. int LP, RP, TP, BP;
  495. laBoxedTheme **BackRef;
  496. laTheme* Parent;
  497. };
  498. STRUCTURE(laSocketRecord){
  499. laListItem Item;
  500. laNodeInSocket* In;
  501. laNodeOutSocket* Out;
  502. };
  503. extern laPropContainer* LA_PC_SOCKET_IN;
  504. extern laPropContainer* LA_PC_SOCKET_OUT;
  505. extern laPropContainer* LA_PROP_SOCKET_SOURCE;
  506. extern laPropContainer* LA_PROP_SOCKET_OUT;
  507. extern laProp* LA_PROP_CONTROLLER;
  508. #define LA_UI_NORMAL 0
  509. #define LA_UI_ACTIVE (1<<0)
  510. #define LA_UI_EDITING (1<<1)
  511. #define LA_UI_DISABLED (1<<8)
  512. #define LA_BT_NORMAL LA_UI_NORMAL
  513. #define LA_BT_ACTIVE LA_UI_ACTIVE
  514. #define LA_BT_BORDER (1<<6)
  515. #define LA_BT_TEXT (1<<7)
  516. #define LA_BT_TEXT_NORMAL (LA_BT_TEXT|LA_UI_NORMAL)
  517. #define LA_BT_TEXT_ACTIVE (LA_BT_TEXT|LA_UI_ACTIVE)
  518. #define LA_BT_DISABLED LA_UI_DISABLED
  519. #define LA_BT_VERTEX (1<<8)
  520. #define LA_BT_EDGE (1<<9)
  521. #define LA_BT_FACE (1<<10)
  522. #define LA_BT_SELECTED (1<<11)
  523. #define LA_BT_SVERTEX (LA_BT_VERTEX|LA_BT_SELECTED)
  524. #define LA_BT_SEDGE (LA_BT_EDGE|LA_BT_SELECTED)
  525. #define LA_BT_SFACE (LA_BT_FACE|LA_BT_SELECTED)
  526. #define LA_UI_TAG_IS_OFFSCREEN (1<<0)
  527. #define LA_UI_TAG_CAVANS_SCALED (1<<1)
  528. #define LA_UI_TAG_NEED_REBUILD (LA_UI_TAG_IS_OFFSCREEN | LA_UI_TAG_CAVANS_SCALED)
  529. #define LA_UI_TAG_SCISSOR (1<<2)
  530. STRUCTURE(laTheme){
  531. laListItem Item;
  532. laSafeString *Name;
  533. laSafeString *Author;
  534. laListHandle Colors;
  535. laListHandle BoxedThemes;
  536. int abc;
  537. //
  538. real ColorBkg[4];
  539. real Color[4];
  540. real AccentColor[4];
  541. real SelectionColor[4];
  542. real CursorColor[4];
  543. real InactiveMix;
  544. real InactiveSaturation;
  545. real CursorAlpha;
  546. real SelectionAlpha;
  547. real WireSaturation;
  548. real WireTransparency;
  549. real WireBrightness;
  550. real VertexColor[4];
  551. real EdgeColor[4];
  552. real SVertexColor[4];
  553. real SEdgeColor[4];
  554. real SFaceColor[4];
  555. real EdgeBrightness, EdgeTransparency;
  556. real VertexBrightness, VertexTransparency;
  557. real SelectedVertexTransparency;
  558. real SelectedEdgeTransparency;
  559. real SelectedFaceTransparency;
  560. };
  561. NEED_STRUCTURE(laOperatorType);
  562. STRUCTURE(laUiType){
  563. laListItem Item;
  564. const char *Identifier;
  565. int ForType;
  566. const char *TargetSub;
  567. //laPropStep FakePs;
  568. laSubProp* FakeProp;
  569. laPropContainer* ExtraProps;
  570. laBoxedTheme **Theme;
  571. laUiDrawFunc Draw;
  572. const char *OperatorID;
  573. laOperatorType *OperatorType;
  574. laUiGetMinWidthFunc GetMinWidth;
  575. laUiGetHeightFunc GetHeight;
  576. laUiDestroyFunc Destroy;
  577. laUiInitFunc Init;
  578. laKeyMapper KeyMapper;
  579. int Tag;
  580. };
  581. NEED_STRUCTURE(laUiItem);
  582. STRUCTURE(laGeneralUiExtraData){
  583. int LastX, LastY;
  584. int TargetIndexVali;
  585. real TargetIndexValf;
  586. int On; //On:Modifying
  587. int Dragging;
  588. laStringEdit *Edit;
  589. void *Ptr1;
  590. void *Ptr2;
  591. int HeightCoeff;
  592. laUiItem* ui;
  593. };
  594. STRUCTURE(laMultiStringExtra){
  595. laGeneralUiExtraData* general;
  596. int PanX, PanY;
  597. };
  598. NEED_STRUCTURE(laCanvasExtra);
  599. typedef void(*laCanvasDrawFunc)(laBoxedTheme* bt, void* DataInstance, laCanvasExtra* Extra);
  600. typedef int (*laModalFunc)(laOperator *, laEvent *);
  601. STRUCTURE(laCanvasTemplate){
  602. laListItem Item;
  603. laSafeString *Identifier;
  604. laCanvasDrawFunc Draw;
  605. laUiDrawFunc SecondDraw;
  606. laKeyMapper KeyMapper;
  607. char *TargetContainerID;
  608. laPropContainer *TargetContainer;
  609. laPropContainer *ExtraProps;
  610. laSubProp *FakeProp;
  611. laModalFunc ExtraModal;
  612. //float LimitYScale;
  613. laUiInitFunc Init;
  614. laUiDestroyFunc Destroy;
  615. };
  616. #define LA_EDIT_ORIGIN_CENTER 0
  617. #define LA_EDIT_ORIGIN_INDIVIDUAL 1
  618. #define LA_EDIT_ORIGIN_CURSOR 2
  619. #define LA_LINE_WIDTH_WARNING_TOO_WIDE 1
  620. #define LA_LINE_WIDTH_WARNING_TOO_THIN 2
  621. #define LA_CANVAS_CURSOR_CROSS 1
  622. #define LA_CANVAS_CURSOR_BOX 2
  623. #define LA_CANVAS_CURSOR_ARROW 3
  624. #define LA_CANVAS_CURSOR_X 4
  625. #define LA_CANVAS_CURSOR_Y 5
  626. #define LA_CANVAS_SELECT_MODE_VERTS 0
  627. #define LA_CANVAS_SELECT_MODE_EDGES 1
  628. //#define LA_CANVAS_SELECT_MODE_FACES 2
  629. #define LA_CANVAS_SELECT_THROUGH_OFF 0
  630. #define LA_CANVAS_SELECT_THROUGH_ON 1
  631. void la_CanvasDrawOverlay(laUiItem *ui, int h);
  632. void la_CanvasInit(laUiItem *ui);
  633. void la_CanvasDestroy(laUiItem *ui);
  634. STRUCTURE(laCanvasExtra){
  635. laListItem Item;
  636. tnsOffscreen *OffScr;
  637. tnsOffscreen *DeferredOffScr;
  638. laUiItem *ParentUi;
  639. real ZoomX;
  640. real ZoomY;
  641. real PanX;
  642. real PanY;
  643. int DrawCursor;
  644. real OnX, TargetX;
  645. real OnY, TargetY;
  646. real ClickedX;
  647. real ClickedY;
  648. int HeightCoeff;
  649. //int SnapBottom;
  650. int ImageDrawAlpha;
  651. int ImageDrawBorder;
  652. int AdaptiveLineWidth;
  653. int LineWidthWarning;
  654. int ClearBackground;
  655. int SelectMode;
  656. int SelectThrough;
  657. int EditCenter;
  658. real BL, BR, BU, BB;
  659. int Dragging;
  660. int TargetIndexVali;
  661. //3d==========
  662. tnsOffscreen *OffScrShadow;
  663. tnsCamera *ViewingCamera; //Always create this one;
  664. tnsCamera *UsingCamera;
  665. int Layers[20];
  666. int DisplayMode;
  667. int ShowFloorGrid;
  668. int GridSize;
  669. int GridSpan;
  670. int ShowAxis[3];
  671. int LineDrawingMode;
  672. };
  673. NEED_STRUCTURE(laUiConditionNode);
  674. STRUCTURE(laConditionUiExtraData){
  675. int a;
  676. laUiItem *EndUi;
  677. laUiItem *ElseUi;
  678. laUiConditionNode *Expression;
  679. //char Remove;
  680. char IsTrue;
  681. };
  682. STRUCTURE(laUiTemplate){
  683. laListItem Item;
  684. laSafeString *Title;
  685. laSafeString *Identifier;
  686. laSafeString *CategoryName;
  687. laUiDefineFunc Define;
  688. laUiDefineFunc Header;
  689. laPanelDetachedPropFunc PropFunc;
  690. laKeyMapper KeyMap;
  691. };
  692. STRUCTURE(laUiItem){
  693. laListItem Item;
  694. laColumn *C;
  695. int L, R, U, B;
  696. int TL, TR, TU, TB;
  697. int AnimationDistinguish;
  698. int State; int Flags; // expand and even (in row control ui)
  699. laPropPack ExtraPP;
  700. laPropStep FakePs;
  701. laGeneralUiExtraData *Extra;
  702. //char NoRefresh;
  703. short Expand;
  704. short SymbolID;
  705. laPropPack PP;
  706. laSafeString *Display;
  707. laSafeString *ExtraInstructions;
  708. laUiType *Type;
  709. laCanvasTemplate *CanvasTemplate;
  710. laUiList *Page; // reuse as row begin ref
  711. laOperatorType *AT; //Probably share in the future;
  712. laStringSplitor *Instructions;
  713. laListHandle Subs;
  714. laUiDefineFunc Template;
  715. int TemplateContext;
  716. laListHandle SubPanels;
  717. };
  718. STRUCTURE(laWidget){
  719. laUiType* Type;
  720. int Flags;
  721. };
  722. #define LA_UI_FLAGS_TRANSPOSE (1<<0)
  723. #define LA_UI_FLAGS_EXPAND (1<<1)
  724. #define LA_UI_FLAGS_ICON (1<<2)
  725. #define LA_UI_FLAGS_CYCLE (1<<3)
  726. #define LA_UI_FLAGS_NO_DECAL (1<<4)
  727. #define LA_UI_FLAGS_NO_EVENT (1<<5)
  728. #define LA_UI_FLAGS_NO_CONFIRM (1<<6)
  729. #define LA_TEXT_ALIGN_LEFT (1<<7)
  730. #define LA_TEXT_ALIGN_RIGHT (1<<8)
  731. #define LA_TEXT_ALIGN_CENTER (1<<9)
  732. #define LA_TEXT_ALIGN_AUTO (1<<10)
  733. #define LA_TEXT_USE_NEWLINE (1<<11)
  734. #define LA_TEXT_LINE_WRAP (1<<12)
  735. #define LA_TEXT_REVERT_Y (1<<13)
  736. #define LA_TEXT_MONO (1<<14)
  737. #define LA_UI_FLAGS_PREFER_BOTTOM (1<<15)
  738. #define LA_UI_FLAGS_NO_GAP (1<<16)
  739. #define LA_UI_FLAGS_UNDERNEATH (1<<17)
  740. #define LA_UI_FLAGS_NO_HEIGHT (LA_UI_FLAGS_NO_GAP|LA_UI_FLAGS_NO_DECAL|LA_UI_FLAGS_UNDERNEATH)
  741. #define LA_UI_FLAGS_NO_OVERLAY (1<<18)
  742. #define LA_TEXT_OVERFLOW_ARROW (1<<19)
  743. #define LA_UI_FLAGS_DISABLED (1<<20)
  744. #define LA_UI_FLAGS_HIGHLIGHT (1<<21)
  745. #define LA_UI_FLAGS_NODE_CONTAINER (1<<22)
  746. #define LA_UI_COLLECTION_NO_HIGHLIGHT LA_TEXT_ALIGN_LEFT
  747. #define LA_TEXT_ONE_LINE (1<<23)
  748. #define LA_UI_FLAGS_INT_ICON (LA_UI_FLAGS_NO_DECAL|LA_UI_FLAGS_NO_EVENT|LA_UI_FLAGS_ICON)
  749. #define LA_UI_FLAGS_PLAIN (LA_UI_FLAGS_NO_DECAL|LA_UI_FLAGS_NO_EVENT)
  750. #define LA_TEXT_ALIGN (LA_TEXT_ALIGN_LEFT|LA_TEXT_ALIGN_CENTER|LA_TEXT_ALIGN_RIGHT|LA_TEXT_ALIGN_AUTO)
  751. #define LA_UI_SOCKET_LABEL_N LA_TEXT_ALIGN_LEFT
  752. #define LA_UI_SOCKET_LABEL_S LA_TEXT_ALIGN_RIGHT
  753. #define LA_UI_SOCKET_LABEL_W LA_TEXT_ALIGN_CENTER
  754. #define LA_UI_SOCKET_LABEL_E LA_TEXT_ALIGN_AUTO
  755. extern laWidget* LA_WIDGET_FIXED_GROUP;
  756. extern laWidget* LA_WIDGET_TAB;
  757. extern laWidget* LA_WIDGET_COLLECTION;
  758. extern laWidget* LA_WIDGET_COLLECTION_ITEM;
  759. extern laWidget* LA_WIDGET_COLLECTION_SELECTOR;
  760. extern laWidget* LA_WIDGET_COLLECTION_SINGLE;
  761. extern laWidget* LA_WIDGET_CONDITION_TOGGLE;
  762. extern laWidget* LA_WIDGET_COLUMN_ADJUSTER;
  763. extern laWidget* LA_WIDGET_COLUMN_VIEWER;
  764. extern laWidget* LA_WIDGET_BUTTON;
  765. extern laWidget* LA_WIDGET_BUTTON_NO_CONFIRM;
  766. extern laWidget* LA_WIDGET_LABEL;
  767. extern laWidget* LA_WIDGET_INT;
  768. extern laWidget* LA_WIDGET_INT_PLAIN;
  769. extern laWidget* LA_WIDGET_INT_PLAIN_ICON;
  770. extern laWidget* LA_WIDGET_VALUE_METER;
  771. extern laWidget* LA_WIDGET_VALUE_METER_2D;
  772. extern laWidget* LA_WIDGET_FLOAT;
  773. extern laWidget* LA_WIDGET_FLOAT_PLAIN;
  774. extern laWidget* LA_WIDGET_FLOAT_COLOR;
  775. extern laWidget* LA_WIDGET_FLOAT_COLOR_HCY;
  776. extern laWidget* LA_WIDGET_ENUM_SELECTOR;
  777. extern laWidget* LA_WIDGET_ENUM_SELECTOR_ICON;
  778. extern laWidget* LA_WIDGET_ENUM_CYCLE;
  779. extern laWidget* LA_WIDGET_ENUM_CYCLE_ICON;
  780. extern laWidget* LA_WIDGET_ENUM_ICON_PLAIN;
  781. extern laWidget *LA_WIDGET_ENUM_HIGHLIGHT;
  782. extern laWidget* LA_WIDGET_STRING;
  783. extern laWidget* LA_WIDGET_STRING_PLAIN;
  784. extern laWidget* LA_WIDGET_STRING_MULTI;
  785. extern laWidget *LA_WIDGET_STRING_MONO_PLAIN;
  786. extern laWidget* LA_WIDGET_MENU_ROOT;
  787. extern laWidget* LA_WIDGET_ALIGN;
  788. extern laWidget* LA_WIDGET_3D_VIEW;
  789. extern laWidget* LA_WIDGET_2D_VIEW;
  790. extern laWidget* LA_WIDGET_SYMBOL;
  791. extern laWidget *LA_WIDGET_NODE_SOCKET;
  792. extern laWidget *LA_WIDGET_HEIGHT_ADJUSTER;
  793. extern laWidget *LA_WIDGET_RAW;
  794. #define LA_CONDITION_TRUE 1
  795. #define LA_CONDITION_FALSE 2
  796. #define LA_CONDITION_GE 3
  797. #define LA_CONDITION_GT 4
  798. #define LA_CONDITION_EQ 5
  799. #define LA_CONDITION_LT 6
  800. #define LA_CONDITION_LE 7
  801. #define LA_CONDITION_AND 8
  802. #define LA_CONDITION_OR 9
  803. #define LA_CONDITION_NOT 10
  804. #define LA_CONDITION_INT 11
  805. #define LA_CONDITION_FLOAT 12
  806. #define LA_CONDITION_STRING 13
  807. #define LA_CONDITION_PROP 14
  808. STRUCTURE(laUiConditionNode){
  809. char a;
  810. int Type;
  811. laUiConditionNode *Expression1; // As Int Value
  812. laUiConditionNode *Expression2;
  813. laUiDescriptor *Base;
  814. char IsExtra;
  815. int IntValue;
  816. real FloatValue;
  817. laSafeString *String; //used as prop path in template
  818. laPropPack PP;
  819. };
  820. #define LA_PANEL_NORMAL 0
  821. #define LA_PANEL_FLOATING_PASSIVE 2
  822. #define LA_PANEL_FLOATING_TOP 3
  823. #define LA_PANEL_NO_PARENT_MENU 4
  824. #define LA_TAG_REDRAW 1
  825. #define LA_TAG_RECALC 2
  826. #define LA_TAG_ANIMATION 4
  827. #define LA_TAG_RECALC_SCROLLER 8
  828. #define LA_PANEL_ANIMATION_DROP_DOWN 1
  829. #define LA_PANEL_ANIMATION_EXPAND 2
  830. #define LA_PANEL_ANIMATION_DISSOVE 3
  831. #define LA_PANEL_ANIMATION_COLLAPSE 4
  832. #define LA_PANEL_ANIMATION_MINIMIZE 5
  833. #define LA_PANEL_ANIMATION_DESTROY 127
  834. NEED_STRUCTURE(laOperator);
  835. NEED_STRUCTURE(laOperator);
  836. STRUCTURE(laPanel){
  837. laListItem Item;
  838. int __SAFE__;
  839. int X, Y, W, H;
  840. int MaxW, MaxH, MinW, MinH;
  841. int TX, TY, TW, TH;
  842. int TitleWidth;
  843. char AnimationMode;
  844. real AnimationRatio;
  845. //int PanX, PanY;
  846. int Show;
  847. short Refresh;
  848. unsigned int FrameDistinguish;
  849. char BoundUi;
  850. char IsMenuPanel;
  851. char LaterDestroy;
  852. char CloseWhenMovedOut;
  853. int Mode;
  854. int LiveEditing;
  855. laUiItem *EditingUi;
  856. laUiItem *FocusingUi;
  857. void *SFPNode;
  858. int SL, SR, ST, SB; //Snap To Edge
  859. laSafeString *Title;
  860. laUiTemplate *PanelTemplate;
  861. laPropPack PP;
  862. laPropStep FakePS;
  863. laPropContainer* PropLinkContainer;
  864. laSubProp* PropLinkFakeProp;
  865. laPropPack PropLinkPP;
  866. laPropStep PropLinkFakePS;
  867. laKeyMapper KeyMap;
  868. laPanelDrawFunc Draw;
  869. laBoxedTheme **BT;
  870. tnsOffscreen *OffScr;
  871. laUiList UI;
  872. laUiList TitleBar;
  873. laUiList *MenuRefer;
  874. laUiDefineFunc UiDefine;
  875. laListHandle SubPanels;
  876. laPanel *Parent;
  877. laBlock *Block;
  878. laOperator *ParentOperator;
  879. u64bit Tag;
  880. //64 Main Types are useable,with 31 subtypes avainable each.
  881. //Main Type 0~63(some are occupied by LA internal)
  882. //Sub Type 0~31
  883. //Main (Low) 0| 1| 2| 3|...
  884. //[---32bits---][---32bits---][---32bits---][---32bits---]...
  885. };
  886. STRUCTURE(laPanelMessage){
  887. laListItem Item;
  888. laSafeString *Message;
  889. };
  890. STRUCTURE(laPanelMessageList){
  891. laListHandle Msg;
  892. };
  893. NEED_STRUCTURE(laOperator);
  894. typedef int (*laInitFunc)(laOperator *);
  895. typedef int (*laRefreshFunc)(laOperator *);
  896. typedef int (*laCheckFunc)(laPropPack *, laStringSplitor *); //this, ui->instructions amd ap->instructions
  897. typedef int (*laExitFunc)(laOperator *, int); //true means Quit, false means Cancel
  898. typedef int (*laInvokeFunc)(laOperator *, laEvent *);
  899. typedef int (*laModalFunc)(laOperator *, laEvent *);
  900. typedef int (*laSystemFunc)(laOperator *, laEvent *);
  901. #define LA_CANCEL 0
  902. #define LA_PASS_ON (1<<10)
  903. #define LA_BLOCK (1<<11)
  904. #define LA_FINISH (1<<12)
  905. #define LA_CONFIRM (1<<13)
  906. #define LA_CANCELED 0
  907. //#define LA_PRE_INVOKE 16384
  908. #define LA_FINISHED (LA_FINISH | LA_BLOCK)
  909. #define LA_FINISHED_PASS (LA_FINISH | LA_PASS_ON)
  910. #define LA_RUNNING LA_BLOCK
  911. #define LA_RUNNING_PASS (LA_BLOCK | LA_PASS_ON)
  912. #define LA_OPERATOR_CALLS_SHUTOFF (LA_FINISHED|(1<<5))
  913. #define LA_EXTRA_TO_PANEL 1
  914. #define LA_EXTRA_CONFIRM 2
  915. #define LA_ACTUATOR_SYSTEM 4
  916. #define LA_ACTUATOR_HIDDEN 8
  917. #define LA_CONFIRM_OK (1<<10)
  918. #define LA_CONFIRM_CANCEL (1<<11)
  919. #define LA_CONFIRM_IGNORE (1<<12)
  920. #define LA_CONFIRM_DATA (1<<13)
  921. #define LA_CONFIRM_CUSTOM_STRING (1<<14)
  922. STRUCTURE(laOperatorType){
  923. laListItem Item;
  924. const char *Identifier;
  925. const char *Name;
  926. const char *Description;
  927. const char *ExtraInstructions;
  928. laInitFunc Init;
  929. laExitFunc Exit;
  930. laInvokeFunc Invoke;
  931. laModalFunc Modal;
  932. laCheckFunc Check;
  933. uint32_t IconID;
  934. laPropContainer* PC;
  935. laUiDefineFunc UiDefine;
  936. laOperatorArgumentParserFunc ParseArgs;
  937. laListHandle Properties;
  938. int ExtraMark;
  939. };
  940. typedef void (*laConfirmDataDestroyFunc)(void *);
  941. STRUCTURE(laConfirmData){
  942. int Mode;
  943. int IData;
  944. real FData;
  945. void *CustomData;
  946. char *StrData;
  947. laConfirmDataDestroyFunc Destroy;
  948. };
  949. STRUCTURE(laOperator){
  950. laListItem Item;
  951. int State;
  952. void *Instance;
  953. void *CustomData;
  954. const char *ExtraInstructions;
  955. laStringSplitor *ExtraInstructionsP;
  956. laPropPack PP;
  957. laPropPack *This;
  958. laConfirmData *ConfirmData;
  959. laConfirmData *NextConfirmData;
  960. laOperator *Child;
  961. laListHandle PropertyStorage;
  962. laOperatorType *Type;
  963. laPropPack *CreatedThis;
  964. int Using;
  965. int StopNow;
  966. laPanel *ToPanel;
  967. laPanel *OperatorPanel;
  968. laListHandle LocalUiLists;
  969. laSafeString* RuntimeHint;
  970. };
  971. #define LA_JS_MAX_AXES 32
  972. #define LA_JS_MAX_BUTTONS 128
  973. STRUCTURE(laController){
  974. laListItem Item;
  975. laSafeString* Name;
  976. laSafeString* Path;
  977. int fd; //device;
  978. int NumButtons; int NumAxes; int UserAssignedID; int Error;
  979. int InternalType; // used to identify models and use specific props.
  980. int AxisValues[LA_JS_MAX_AXES];
  981. char ButtonValues[LA_JS_MAX_BUTTONS];
  982. };
  983. void la_InitControllers();
  984. void la_UpdateControllerStatus();
  985. void la_RegisterControllerProps();
  986. laPropContainer* laget_ControllerType(laController* c);
  987. laController* la_FindControllerWithID(int id);
  988. void la_RegisterInputMapperOperators();
  989. #define LA_DAG_FLAG_ERR 0
  990. #define LA_DAG_FLAG_TEMP 1
  991. #define LA_DAG_FLAG_PERM 2
  992. void laMappingRequestRebuild();
  993. void laMappingRequestEval();
  994. int la_RebuildInputMapping();
  995. int la_RunInputMapping();
  996. void laDriverRequestRebuild();
  997. void laDriverRequestEval();
  998. int la_RebuildDriverEval();
  999. int la_RunDrivers();
  1000. laBaseNode* la_CreateDriverNode(laNodeRack* ir, laBaseNodeType* NodeType);
  1001. laBaseNode* la_CreateInputMapperNode(laNodeRack* ir, laBaseNodeType* NodeType);
  1002. laPropContainer* laget_BaseNodeType(laBaseNode* bn);
  1003. void laRegisterNode(laBaseNodeType* type, laPropContainer* pc,
  1004. laBaseNodeInitF init, laBaseNodeDestroyF destroy, laBaseNodeVisitF visit, laBaseNodeEvalF eval,
  1005. int nodesize, char* udf_string, char* type_string, char* UiText, int icon);
  1006. void latouched_NodeInSocket(void* unused, int hint);
  1007. #define LA_BASE_NODE_HEADER(uil,c,This)\
  1008. {laSplitColumn(uil,c,0.2);laColumn*c1=laLeftColumn(c,1);c=laRightColumn(c,0);\
  1009. laShowHeightAdjuster(uil,c1,This,"base.__gap",0);}
  1010. #define LA_IDN_REGISTER(uitext,icon,a,pc,init,destroy,visit,eval,type)\
  1011. laRegisterNode(&a,pc,init,destroy,visit,eval,sizeof(type),"UDFRES_" #type, #type, uitext,icon);
  1012. #define LA_SRC_AND_PARENT(socket)\
  1013. ((socket)->Source && (socket)->Source->Parent)
  1014. #define LA_VISIT_NODE(node)\
  1015. {int result=node->Type->Visit(node,l); if(result!=LA_DAG_FLAG_PERM) return LA_DAG_FLAG_ERR;}
  1016. #define LA_GUARD_THIS_NODE(n)\
  1017. {if(n->Base.Eval==LA_DAG_FLAG_PERM) return LA_DAG_FLAG_PERM; if(n->Base.Eval==LA_DAG_FLAG_TEMP) return LA_DAG_FLAG_ERR; n->Base.Eval=LA_DAG_FLAG_TEMP; }
  1018. extern laBaseNodeType LA_IDN_KEYBOARD;
  1019. extern laBaseNodeType LA_IDN_MOUSE;
  1020. extern laBaseNodeType LA_IDN_CONTROLLER;
  1021. extern laBaseNodeType LA_IDN_VISUALIZER;
  1022. extern laBaseNodeType LA_IDN_SPLIT;
  1023. extern laBaseNodeType LA_IDN_SWITCH;
  1024. extern laBaseNodeType LA_IDN_COMBINE;
  1025. extern laBaseNodeType LA_IDN_VALUES;
  1026. extern laBaseNodeType LA_IDN_MATRIX;
  1027. extern laBaseNodeType LA_IDN_MATH;
  1028. extern laBaseNodeType TNS_IDN_TRANSFORM;
  1029. extern laBaseNodeType TNS_IDN_MAKE_TRANSFORM;
  1030. extern laNodeCategory* LA_NODE_CATEGORY_INPUT;
  1031. extern laNodeCategory* LA_NODE_CATEGORY_MATH;
  1032. extern laNodeCategory* LA_NODE_CATEGORY_ROUTE;
  1033. extern laNodeCategory* LA_NODE_CATEGORY_DRIVER;
  1034. #define LA_VALUES_NODE_FLOAT 0
  1035. #define LA_VALUES_NODE_INT 1
  1036. #define LA_VALUES_NODE_ENUM 2
  1037. #define LA_MATRIX_NODE_OP_MUL 0
  1038. #define LA_MATRIX_NODE_OP_INV 1
  1039. #define LA_MATH_NODE_OP_ADD 0
  1040. #define LA_MATH_NODE_OP_SUB 1
  1041. #define LA_MATH_NODE_OP_MUL 2
  1042. #define LA_MATH_NODE_OP_DIV 3
  1043. #define LA_MATH_NODE_OP_POW 4
  1044. #define LA_MATH_NODE_OP_LOG 5
  1045. #define LA_MATH_NODE_OP_SIN 6
  1046. #define LA_MATH_NODE_OP_COS 7
  1047. #define LA_MATH_NODE_OP_TAN 8
  1048. #define LA_MATH_NODE_OP_ASIN 9
  1049. #define LA_MATH_NODE_OP_ACOS 10
  1050. #define LA_MATH_NODE_OP_ATAN 11
  1051. #define LA_MATH_NODE_OP_ATAN2 12
  1052. STRUCTURE(laRackPage){
  1053. laListItem Item;
  1054. laSafeString* Name;
  1055. laListHandle Racks;
  1056. };
  1057. #define LA_RACK_TYPE_INPUT (1<<0)
  1058. #define LA_RACK_TYPE_DRIVER (1<<1)
  1059. #define LA_RACK_TYPE_ALL (LA_RACK_TYPE_DRIVER|LA_RACK_TYPE_INPUT)
  1060. STRUCTURE(laNodeRack){
  1061. laListItem Item;
  1062. laSafeString* Name;
  1063. laListHandle Nodes;
  1064. laRackPage* ParentPage;
  1065. int RackType;
  1066. };
  1067. NEED_STRUCTURE(laInputControllerNode);
  1068. STRUCTURE(laInputControllerNodeSocket){
  1069. laInputControllerNode* Parent;
  1070. laSafeString* Which;
  1071. laNodeOutSocket* Out;
  1072. int Offset;
  1073. int IntVal[8]; real RealVal[8];
  1074. };
  1075. STRUCTURE(laInputControllerNode){
  1076. laBaseNode Base;
  1077. laInputControllerNodeSocket Sockets[8];
  1078. int UserID;
  1079. int Mode;// btn/axis;
  1080. };
  1081. STRUCTURE(laInputVisualizerNode){
  1082. laBaseNode Base;
  1083. laNodeInSocket* In;
  1084. int IntVal[8]; real RealVal[8];
  1085. };
  1086. STRUCTURE(laSplitNodeOutSocket){
  1087. laNodeOutSocket* Out;
  1088. };
  1089. STRUCTURE(laSplitNode){
  1090. laBaseNode Base;
  1091. laNodeInSocket* In;
  1092. laSplitNodeOutSocket Out[8];
  1093. int IntVal[8]; real RealVal[8];
  1094. int ArrLen;
  1095. };
  1096. STRUCTURE(laSwitchNodeInSocket){
  1097. laNodeInSocket* In;
  1098. };
  1099. STRUCTURE(laSwitchNode){
  1100. laBaseNode Base;
  1101. laSwitchNodeInSocket In[8];
  1102. laNodeOutSocket* Out;
  1103. laNodeInSocket* SwitchIn;
  1104. real TempVal;
  1105. int Switch;
  1106. };
  1107. STRUCTURE(laCombineNode){
  1108. laBaseNode Base;
  1109. laSwitchNodeInSocket In[8];
  1110. laNodeOutSocket* Out;
  1111. laNodeOutSocket* OutInt;
  1112. laNodeOutSocket* OutEnum;
  1113. real Values[8]; int ValuesI[8];
  1114. };
  1115. STRUCTURE(laValuesNode){
  1116. laBaseNode Base;
  1117. laSplitNodeOutSocket Out[8];
  1118. real Values[8]; int ValuesI[8], ValuesE[8];
  1119. int Modes[8];
  1120. };
  1121. STRUCTURE(laMatrixNode){
  1122. laBaseNode Base;
  1123. laNodeInSocket *InL,*InR;
  1124. laNodeOutSocket* Out;
  1125. tnsMatrix44d Mat;
  1126. int Operation;
  1127. };
  1128. STRUCTURE(laMathNode){
  1129. laBaseNode Base;
  1130. laNodeInSocket *InL,*InR;
  1131. laNodeOutSocket* Out,*OutInt;
  1132. real Value; int ValueI;
  1133. real ValueL, ValueR;
  1134. int Operation;
  1135. };
  1136. STRUCTURE(laNodeCategory){
  1137. laListItem Item;
  1138. laSafeString* Name;
  1139. laListHandle NodeTypes;//lip
  1140. laUiDefineFunc Ui;
  1141. int For;
  1142. };
  1143. #define LA_INPUT_CONTROLLER_NODE_MODE_BTN 0
  1144. #define LA_INPUT_CONTROLLER_NODE_MODE_AXIS 1
  1145. void logPrintT(int Type, char* format, ...);
  1146. void logPrint(char* format, ...);
  1147. void logPrintNew(char* format, ...);
  1148. int LA_WindowProc(Window win, int message, int wparam, int lparam);
  1149. void la_RegisterMainOperators();
  1150. void la_RegisterUiOperatorsBasic();
  1151. void la_RegisterBuiltinOperators();
  1152. void la_RegisterModellingOperators();
  1153. void la_RegisterUiTypesBasic();
  1154. void la_RegisterUiTypesViewerWidgets();
  1155. void la_RegisterBuiltinTemplates();
  1156. void la_RegisterWindowKeys();
  1157. void la_RegisterGeneralProps();
  1158. void la_RegisterInternalProps();
  1159. void la_RegenerateWireColors();
  1160. void laui_IntPropInfo(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *ExtraColumns, int context);
  1161. void laui_FloatPropInfo(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *ExtraColumns, int context);
  1162. void laui_DefaultPropDetails(laUiList *uil, laPropPack *This, laPropPack *Extra, laColumn *UNUSED, int context);
  1163. void laui_DefaultNodeOperationsPropUiDefine(laUiList *uil, laPropPack *This, laPropPack *OperatorProps, laColumn *UNUSED, int context);
  1164. void laui_DefaultPropUiDefine(laUiList *uil, laPropPack *This, laPropPack *OperatorProps, laColumn *UNUSED, int context);
  1165. void laui_StringPropUiDefine(laUiList *uil, laPropPack *This, laPropPack *Extra, laColumn *UNUSED, int context);
  1166. void laui_IdentifierOnly(laUiList *uil, laPropPack *This, laPropPack *OP_UNUSED, laColumn *Extra, int context);
  1167. void laui_SubPropInfoDefault(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1168. void laui_SubPropSelection(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1169. void laui_LinkerSelectionProp(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1170. void laui_LinkerSelectionInstance(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1171. void laui_DefaultOperatorPanelTitleBar(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1172. void laui_ColumnItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1173. void laui_DefaultMenuButtonsFileEntries(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
  1174. void laui_DefaultMenuButtonsOptionEntries(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
  1175. void laui_DefaultMenuButtons(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
  1176. void laui_DefaultMenuExtras(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
  1177. void laui_DefaultMenuBarActual(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
  1178. void laui_DefaultSubWindowMenuBarActual(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);
  1179. void laui_ThemeListItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1180. void laui_Theme(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1181. void laui_BoxedThemeItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1182. void laui_PropertyContainerList(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1183. void laui_WindowListItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1184. void laui_LayoutListItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1185. void laui_PanelListItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1186. void laui_InputSocketItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1187. void laui_OutputSocketItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1188. void tnsui_GroupItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1189. void tnsui_ObjectGroupItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1190. void tnsui_GroupObjectItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1191. void tnsui_MaterialItem(laUiList *uil, laPropPack *Base, laPropPack *UNUSED_This, laColumn *UNUSED_Colums, int context);
  1192. void laui_FileBrowserFileItem(laUiList *uil, laPropPack *This, laPropPack *OP_UNUSED, laColumn *Extra, int context);
  1193. void laui_FileBrowserDiskItem(laUiList *uil, laPropPack *This, laPropPack *OP_UNUSED, laColumn *Extra, int context);
  1194. void laui_LinkerPanel(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1195. void laui_ManagedUDFItem(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1196. void laui_ManagedUDFOps(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1197. void laui_ManagedProp(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1198. void laui_ManagedSavePanel(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1199. void laui_ManagedUDFPanel(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1200. void laui_FileBrowserFileList(laUiList *uil, laPropPack *THIS_UNUSED, laPropPack *Operator, laColumn *UNUSED, int context);
  1201. void laui_DataRestorePage(laUiList *uil, laPropPack *THIS_UNUSED, laPropPack *Operator, laColumn *UNUSED, int context);
  1202. void laui_ResourceFolderItem(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1203. void laui_LogItem(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);
  1204. void laui_NodeCategory(laUiList *uil, laPropPack *This, laPropPack *Extra, laColumn *UNUSED, int context);
  1205. int OPINV_UiItem(laOperator *a, laEvent *e);
  1206. int OPEXT_UiItem(laOperator *a, int ExitCode);
  1207. int la_ArrayGetHeight(laUiItem *ui);
  1208. int la_ValueGetHeight(laUiItem*ui);
  1209. int la_3DViewGetHeight(laUiItem *ui);
  1210. int la_CanvasGetHeight(laUiItem *ui);
  1211. int la_EnumGetHeight(laUiItem *ui);
  1212. int la_ColorPickerGetHeight(laUiItem *ui);
  1213. int la_SymbolGetHeight(laUiItem *ui);
  1214. int la_GroupGetHeight(laUiItem *ui);
  1215. laPanel *la_FindFreePanelByTemplate(laWindow *w, const laUiTemplate *uit);
  1216. laUiItem *la_FindUiWithMark(laUiList *uil, char *mark);
  1217. laUiList *la_FindSubListWithInstance(laUiItem *ui, void *Instance);
  1218. #define LA_FILETYPE_UNKNOWN 0
  1219. #define LA_FILETYPE_UDF 1
  1220. #define LA_FILETYPE_DOCUMENT 2
  1221. #define LA_FILETYPE_IMAGE 3
  1222. #define LA_FILETYPE_AUDIO 4
  1223. #define LA_FILETYPE_VIDEO 5
  1224. #define LA_FILETYPE_COMPRESSED 6
  1225. #define LA_FILETYPE_FONT 7
  1226. #define LA_FILETYPE_VECTOR 8
  1227. #define LA_FILETYPE_WEBPAGE 9
  1228. #define LA_FILETYPE_META 10
  1229. #define LA_FILETYPE_BLEND 11
  1230. #define LA_FILETYPE_PDF 13
  1231. #define LA_FILETYPE_EXEC 14
  1232. #define LA_FILETYPE_SYS 15
  1233. #define LA_FILETYPE_FOLDER 16
  1234. #define LA_FILETYPE_LASDEXCHANGE 17
  1235. #define LA_FILE_SELECT_FILE 0
  1236. #define LA_FILE_SELECT_FOLDER 1
  1237. STRUCTURE(laFileItem){
  1238. laListItem Hyper;
  1239. int IsFolder;
  1240. char Name[1024];
  1241. int Size;
  1242. laTimeInfo TimeModified;
  1243. int Type;
  1244. };
  1245. STRUCTURE(laDiskItem){
  1246. laListItem Hyper;
  1247. char ID;
  1248. real Total_GB;
  1249. real Free_GB;
  1250. };
  1251. STRUCTURE(laFileBrowser){
  1252. laListItem Hyper;
  1253. char Path[1024];
  1254. char FileName[512];
  1255. laDiskItem *RootDisk;
  1256. laFileItem *Active;
  1257. laListHandle FileList;
  1258. laListHandle Disks;
  1259. int SelectFolder;
  1260. };
  1261. STRUCTURE(laUDFPreviewExtra){
  1262. laUDF *UDF;
  1263. laListHandle ContentNodes;
  1264. int Opened;
  1265. };
  1266. STRUCTURE(laManagedSaveExtra){
  1267. int ShowPage;
  1268. int OnExit;
  1269. };
  1270. #define LA_UDF_SHARE_POINTER(id) \
  1271. la_UDFAppendSharedTypePointer("" #id, id)
  1272. laCanvasTemplate *la_GetCanvasTemplate(char *TargetContainerID, char* TemplateID);
  1273. laPropContainer* laUiHasExtraProps(laUiType *ut, int size, int hyper);
  1274. laPropContainer* laCanvasHasExtraProps(laCanvasTemplate *ct, int size, int hyper);
  1275. laUiType *la_RegisterUiType(const char *Identifer, int ForType, const char *UseOperator, laBoxedTheme **bt, laUiDrawFunc *Draw, laUiGetHeightFunc GetHeight, laUiInitFunc Init, laUiDestroyFunc Destroy);
  1276. void laSetWindowCursor(int id);
  1277. void laRenameWindow(laWindow* wnd, char* name);
  1278. void laSaveUserPreferences();
  1279. void laEnsureUserPreferences();
  1280. int laGetReady();
  1281. void laSetFrameCallbacks(laPreFrameF PreFrame, laPreDrawF PreDraw, laPostFrameF PostFrame);
  1282. void laSetCleanupCallback(laCleanupF Cleanup);
  1283. laWindow *laDesignWindow(int X, int Y, int W, int H);
  1284. laLayout *laDesignLayout(laWindow *w, char *Title);
  1285. void laFoldBlockTitle(laBlock* b);
  1286. void laUnfoldBlockTitle(laBlock* b);
  1287. void laMaximizeBlock(laBlock* b);
  1288. void laRestoreToLayout();
  1289. void laMaximizeCanvasUI(laUiItem* ui, laPanel* UiParentPanel);
  1290. void laRestoreCanvasUI();
  1291. void laHideMenuBar();
  1292. void laShowMenuBar();
  1293. void laSplitBlockHorizon(laBlock *b, real Percentage);
  1294. void laSplitBlockVertical(laBlock *b, real Percentage);
  1295. void laCombineChildBlocks(laBlock *b);
  1296. laBlock *laBlock1(laBlock *b);
  1297. laBlock *laBlock2(laBlock *b);
  1298. laBlock *laSwapSubBlocks(laBlock *b);
  1299. void laDestroyBlocksRecursive(laBlock *Root);
  1300. laPanel* laTearOffPanel(laBlock* b, laPanel* p_if_set);
  1301. void laDockPanel(laWindow* from, laBlock* b, laPanel* p);
  1302. laPanel *laCreatePanel(laBlock *b, char *template_id);
  1303. laPanel *laCreateTopPanel(laWindow *w, char *template_id, int X, int Y, int W, int H, int MaxW, int MaxH, int MinW, int MinH, int SnapL, int SnapR, int SnapT, int SnapB);
  1304. void laShowPanel(laPanel *p);
  1305. void laShowPanelWithDropDownEffect(laPanel *p);
  1306. void laShowPanelWithExpandEffect(laPanel *p);
  1307. void laHidePanel(laPanel *p);
  1308. void laHidePanelWithDissoveEffect(laPanel *p);
  1309. void laActivatePanel(char* TemplateID, int x, int y);
  1310. void laPanPanel(laPanel *p, int DeltaX, int DeltaY);
  1311. int laPanUiListFree(laUiList *uil, int X, int Y);
  1312. int laPanUiList(laUiList *uil, int X, int Y, int L, int R, int U, int B);
  1313. int laPanUiListAuto(laUiList *uil, int X, int Y, int L, int R, int U, int B);
  1314. int laScaleUiList(laUiList *uil, real factor, int L, int R, int U, int B);
  1315. laPanel *laDesignPropPanel(char *Title, int X, int Y, int W, int H,
  1316. laUiDefineFunc Define, laPropPack *This, laPropPack *OperatorProps);
  1317. laPanel *laDesignOperatorPanel(char *Title, int X, int Y, int W, int H, int MaxW, int MaxH, int MinW, int MinH, int SnapL, int SnapR, int SnapT, int SnapB,
  1318. laUiDefineFunc Define, laPropPack *This, laPropPack *OperatorProps);
  1319. void laDeferedDestroyPanel(laPanel *p);
  1320. void laDestroySinglePanel(laPanel *p, int immediate);
  1321. void laEnsurePanelInBound(laPanel *p,laUiList* uil);
  1322. int laEnclosePanelContent(laPanel *p, laUiList *uil);
  1323. laPanel *laEnableIdlePanel(laPanel *Attachment, laOperator *a, laPropPack *OperatorProps, laUiDefineFunc ReplaceUiDefine, laPropPack *This,
  1324. int L, int R, int B, int MaxGH, int MaxW, laEvent *e);
  1325. laPanel *laEnablePropertyPanel(laPanel *Attachment, laOperator *a, laPropPack *OperatorProps, laUiDefineFunc ReplaceUiDefine, laUiDefineFunc FallBackUiDefine, laPropPack *This,
  1326. int L, int R, int B, int MaxGH, int MaxW, laEvent *e);
  1327. laPanel *laEnableEmptyPropertyPanel(laPanel *Attachment, laOperator *a, int L, int R, int U, int MaxGH, laEvent *e);
  1328. laPanel *laEnableMenuPanel(laPanel *Attachment, laOperator *a, laUiList *MenuRefer, laPropPack *This,
  1329. int L, int R, int B, int MaxGH, int MaxW, laEvent *e);
  1330. laPanel *laDefineAndEnableMenuPanel(laPanel *Attachment, laOperator *a, laPropPack *This,
  1331. int L, int B, int MaxGH, int MaxW, laEvent *e);
  1332. laPanel *laEnableOperatorPanel(laOperator *For, laPropPack *This, int X, int Y, int W, int H, int MaxW, int MaxH, int MinW, int MinH, int SnapL, int SnapR, int SnapT, int SnapB, laEvent *e);
  1333. laPanel *laEnableYesNoPanel(laOperator *a, laPanel *Attachment, char *Title, char *Message, int X, int Y, int W, laEvent *e);
  1334. laPanel *laEnableMessagePanel(laOperator *a, laPanel *Attachment, char *Title, char *Message, int X, int Y, int W, laEvent *e);
  1335. laPanel *laEnableMultiMessagePanel(laOperator *a, laPanel *Attachment, char *Title, laPanelMessageList *pml, int X, int Y, int W, laEvent *e);
  1336. void laAddPanelMessage(laPanelMessageList *pml, char *Message);
  1337. void la_PropPanelUserRemover(void* This, laItemUserLinker* iul);
  1338. void la_EnsurePanelExtras(laPanel *p);
  1339. void laRedrawAllWindows();
  1340. void laRedrawCurrentWindow();
  1341. void laRedrawCurrentPanel();
  1342. void laRecalcCurrentPanel();
  1343. void laRecalcPanelImmediate(laPanel *p);
  1344. void laRecalcCurrentPanelImmediate();
  1345. int laNonFixedPanelExists(laPanel *p);
  1346. int laIsInPanel(laPanel *p, int PanelX, int PanelY);
  1347. int laIsCloseToPanel(laPanel *p, int PanelX, int PanelY);
  1348. void laPopPanel(laPanel *p);
  1349. int laPanelOverlappingEachOther(laPanel *p1, laPanel *p2);
  1350. void laUnlinkSharedPanel(laPanel *p);
  1351. int laIsPanelCovered(laPanel *p);
  1352. int laIsTopPanel(laPanel *p);
  1353. laPanel *laDetectPanel(int X, int Y);
  1354. void laWindowToLocal(laOperator *a, laPanel *p, int *x, int *y);
  1355. void laPanelToLocal(laOperator *a, int *x, int *y);
  1356. void laLocalToWindow(laOperator *a, laPanel *p, int *x, int *y);
  1357. void laLocalToPanel(laOperator *a, int *x, int *y);
  1358. void laSetNextMenuPos(int X, int Y, int W, int H);
  1359. int laIsInBlock(laBlock *b, int X, int Y);
  1360. int laIsInBlockHeader(laBlock *b, int X, int Y);
  1361. int laIsInBlockBotton1(laBlock *b, int X, int Y);
  1362. int laIsInBlockBotton2(laBlock *b, int X, int Y);
  1363. laBlock *laDetectBlockRecursive(laBlock *b, int X, int Y);
  1364. laUiList *laPrepareUi(laPanel *p);
  1365. laColumn *laFirstColumn(laUiList *uil);
  1366. laColumn *laSplitColumn(laUiList *uil, laColumn *c, real Percent);
  1367. laColumn *laSplitColumnDescriptor(laUiDescriptor *ud, laColumn *c, real Percent);
  1368. laColumn *laLeftColumn(laColumn *c, int MaxWidth);
  1369. laColumn *laRightColumn(laColumn *c, int MaxWidth);
  1370. int laCheckAndMergeSubColumnsUiList(laUiList *TopUil, laColumn *c, int DoMerge);
  1371. int laCheckAndMergeSubColumnsDescriptor(laUiDescriptor *TopDescriptor, laColumn *c, int DoMerge);
  1372. laUiConditionNode *laTrue();
  1373. laUiConditionNode *laFalse();
  1374. laUiConditionNode *laPropExpression(laPropPack *Base, char *Prop);
  1375. laUiConditionNode *laIntExpression(int Value);
  1376. laUiConditionNode *laFloatExpression(real Value);
  1377. laUiConditionNode *laStringExpression(char *Content);
  1378. laUiConditionNode *laAnd(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
  1379. laUiConditionNode *laOr(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
  1380. laUiConditionNode *laNot(laUiConditionNode *Expression1);
  1381. laUiConditionNode *laEqual(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
  1382. laUiConditionNode *laGreaterThan(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
  1383. laUiConditionNode *laLessThan(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
  1384. laUiConditionNode *laGreaterEqual(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
  1385. laUiConditionNode *laLessEqual(laUiConditionNode *Expression1, laUiConditionNode *Expression2);
  1386. laUiItem *laShowLabel(laUiList *uil, laColumn *c, const char *Content, laUiDefineFunc Template, laWidget* Widget);
  1387. laUiItem *laShowLabelDynamic(laUiList *uil, laColumn *c, const char *Content, laUiDefineFunc Template, laWidget* Widget);
  1388. laUiItem *laShowIcon(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, laWidget* Widget);
  1389. laUiItem *laShowItem(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path);
  1390. laUiItem *laShowItemFull(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, laWidget* Widget, char* instructions, laUiDefineFunc Template, int TemplateContext);
  1391. laUiItem *laShowNodeSocket(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, char* instructions);
  1392. laUiItem *laShowHeightAdjuster(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, char* instructions);
  1393. laUiItem *laShowDetachedItem(laPanel *p, laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, const char *Rename, laUiDefineFunc Template, laWidget* Widget);
  1394. laUiItem *laShowCanvas(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, const char *id2DTemplate, int Height);
  1395. laUiItem *laShow2DContainerItem(laUiList *uil, laColumn *c, laPropPack *Base, const char *Path, int Height);
  1396. void laDefault3DViewOverlay(laUiItem *ui);
  1397. void laDefault2DViewOverlayRight(laUiItem *ui);
  1398. laUiItem *laShowColumnAdjuster(laUiList *uil, laColumn *c);
  1399. laUiItem *laShowSymbol(laUiList *uil, laColumn *c, int SymbolID, int Height);
  1400. laUiItem *laBeginRow(laUiList *uil, laColumn *c, int Expand, int Even);
  1401. laUiItem *laEndRow(laUiList *uil, laUiItem* Begin);
  1402. laUiItem *laMakeGroup(laUiList *uil, laColumn *c, const char *Name, laWidget* Widget);
  1403. laUiItem *laMakeFoldableGroup(laUiList *uil, laColumn *c, const char *Name, laWidget* Widget, int DefaultFolded, int ButtonFlags);
  1404. laUiItem *laMakeEmptyGroup(laUiList *uil, laColumn *c, const char *Name, laWidget* Widget);
  1405. void laEndFoldableGroup(laUiList *sub, laUiItem *group);
  1406. laUiItem *laMakeTab(laUiList *uil, laColumn *c, laWidget* Widget);
  1407. laUiList *laAddTabPage(laUiItem *ui, const char *Name);
  1408. laUiItem *laOnConditionThat(laUiList *uil, laColumn *c, laUiConditionNode *Expression);
  1409. laUiItem *laOnConditionToggle(laUiList *uil, laColumn *col, laUiDefineFunc define, int Remove, laPropPack *ExtraBase, laPropPack *ExtraThis, laWidget* Widget);
  1410. laUiItem *laEndCondition(laUiList *uil, laUiItem *Beginner);
  1411. laUiItem *laElse(laUiList *uil, laUiItem *Beginner);
  1412. laUiList *laMakeMenuPage(laUiList *uil, laColumn *c, const char *Title);
  1413. laUiItem *laShowSeparator(laUiList *uil, laColumn *widest);
  1414. void laFixHeight(laUiList *uil, short Rows);
  1415. void la_ConditionerInit(laUiItem *ui, laUiConditionNode *Expression);
  1416. void laMakeExtraColumns(laUiItem *ui, u8bit HowMany, ...);
  1417. int la_UiInBoundEx(laUiItem *ui, laUiListDraw *uild);
  1418. void la_DestroyUiRange(laUiList *uil, laUiItem *Begin, laUiItem *End);
  1419. void la_ClearUiSpecificData(laUiItem *ui);
  1420. laUiItem *la_UpdatePropDisplay(laUiItem *ui, laPropPack *Base, const char *Path, laUiDefineFunc Template, laWidget* Widget, char* instructions);
  1421. laUiItem *la_UpdateLabelDisplay(laUiItem *ui, laUiDefineFunc Template, char *Content);
  1422. laUiItem *la_ShowGeneralPropItem(laUiList *uil, laColumn *c, laPropPack *Base, laProp *GeneralProp, laProp *p, laUiDefineFunc Template, laWidget* Widget);
  1423. void laFinalizeUiTemplates();
  1424. laUiTemplate *laFindUiTemplate(char *Identifier);
  1425. void la_DestroyUiTemplate(laUiTemplate* uit);
  1426. void la_DestroyCanvasTemplate(laCanvasTemplate* uit);
  1427. laUiTemplate *laRegisterUiTemplate(char *Identifier, char* Title, laUiDefineFunc func,laPanelDetachedPropFunc PropFunc, laUiDefineFunc header, char* NewCategory);
  1428. laCanvasTemplate *laRegisterCanvasTemplate(char *Identifier, char *ForContainer, laModalFunc ExtraModal, laCanvasDrawFunc Func, laUiDrawFunc SecondDraw, laUiInitFunc CustomInit, laUiDestroyFunc CustomDestroy);
  1429. void laGet2DViewRange(laCanvasExtra *e, int *L, int *R, int *U, int *B);
  1430. void laGet2DViewRanged(laCanvasExtra *e, real *L, real *R, real *U, real *B);
  1431. void laGet2DViewRangeW(laCanvasExtra *e, int *L, int *R);
  1432. void laGet2DViewRangeWd(laCanvasExtra *e, real *L, real *R);
  1433. void la_DestroyTheme(laTheme* t);
  1434. laTheme *laDesignTheme(const char *Name, const char *AuthorName);
  1435. laBoxedTheme *laDesignBoxedTheme(laTheme *t, const char *Name, laBoxedTheme** BackRef,
  1436. real NormalY,real ActiveY,real BorderY,real TextY,real TextActiveY, real Alpha,
  1437. real TopMargin, real LeftMargin, real RightMargin, real BottomMargin,
  1438. real TopPadding, real LeftPadding, real RightPadding, real BottomPadding);
  1439. laBoxedTheme *laGetTheme(const char *ThemeName);
  1440. laBoxedTheme *laGetBoxedTheme(const char *ThemeName, const char *BoxName);
  1441. real* laThemeColor(laBoxedTheme* bt, int which);
  1442. real* laAccentColor(int which);
  1443. void la_RefreshBoxedThemeColor(laBoxedTheme* bt);
  1444. void la_RefreshThemeColorSelf(laTheme* th);
  1445. void la_RefreshThemeColor(laTheme* th);
  1446. #define LA_COLOR4(c) (c)[0], (c)[1], (c)[2], (c)[3]
  1447. #define LA_COLOR3(c) (c)[0], (c)[1], (c)[2]
  1448. #define LA_VEC2(c) (c)[0], (c)[1]
  1449. #define LA_SET3(c, a1,a2,a3) { (c)[0]=a1; (c)[1]=a2; (c)[2]=a3; }
  1450. int laIsInUiItem(laUiItem *ui, int x, int y);
  1451. int laIsInBound(int x, int y, int l, int r, int u, int b);
  1452. laUiItem *la_DetectUiItemRecursive(laUiList *uil, int x, int y, int LimB, laListHandle *LocalBuf, int Deep);
  1453. laUiItem *la_DetectSocketRecursive(laUiList* uil, int x, int y, int LimB, laPropContainer* PCInOrOut);
  1454. laUiList *la_DetectUiListRecursive(laUiList *uil, int x, int y, int LimH,
  1455. laUiItem **ParentUi, laUiList **ScrollUil, laUiList **ContainerParent, int InToContainerUI, laUiItem *Exception);
  1456. laUiList *la_DetectUiListRecursiveDeep(laUiList *uil, int x, int y, int LimH, laUiItem **ParentUi, laUiList **ScrollUil,
  1457. laUiList **ContainerParent, int InToContainerUI, laUiItem *Exception, laListHandle* levels);
  1458. int laStartWindow(laWindow *w);
  1459. void laSetMenuBarTemplates(laUiDefineFunc MenuButtons, laUiDefineFunc MenuExtras, const char* ProgramName);
  1460. void laMainLoop();
  1461. void la_DestroyOperatorType(laOperatorType* at);
  1462. laOperatorType *laCreateOperatorType(const char *ID, const char *Name, const char *Description,
  1463. laCheckFunc Check, laInitFunc Init, laExitFunc Exit, laInvokeFunc Invoke, laModalFunc Modal,
  1464. uint32_t IconID, int ExtraMark);
  1465. laPropContainer* laDefineOperatorProps(laOperatorType* ot, int HyperLevel);
  1466. laNodeOutSocket* laCreateOutSocket(void* NodeParentOptional, char* label, int DataType);
  1467. laNodeInSocket* laCreateInSocket(char* label, int DataType);
  1468. void laDestroyInSocket(laNodeInSocket* s);
  1469. void laDestroyOutSocket(laNodeOutSocket* s);
  1470. laNodeCategory* laAddNodeCategory(char* Name,laUiDefineFunc* Ui,int ForRackTypes);
  1471. void laNodeCategoryAddNodeTypes(laNodeCategory* nc, ...);
  1472. void laFreeKeyMapItem(laKeyMapItem* kmi);
  1473. laKeyMapItem *laAssignNewKey(laKeyMapper *km, char *Path, char *Operation, char SelectBase, int SpecialKeyBits, int EventType, int Key, char *ExtraInstructions);
  1474. int laKeyMapExecuteEvent(laOperator *from, laKeyMapper *km, laEvent *e);
  1475. int laKeyMapExecuteEventEx(laOperator *from, laPropPack *UiExtra, laKeyMapper *km, laEvent *e);
  1476. laOperatorType *laGetOperatorType(const char *ID);
  1477. void laSetOperatorLocalizer(void *ToPanel);
  1478. int laOperatorAvailable(char *ID, laPropPack *This, laStringSplitor *Instructions);
  1479. int laOperatorAvailableP(laOperatorType *at, laPropPack *This, laStringSplitor *Instructions);
  1480. int laOperatorAvailableSafe(char *ID, laPropPack *This, void *Real_FromInstance, laStringSplitor *Instructions);
  1481. int laOperatorAvailablePSafe(laOperatorType *at, laPropPack *This, void *Real_FromInstance, laStringSplitor *Instructions);
  1482. void laSendOperatorTriggerEvent();
  1483. void laRetriggerOperators();
  1484. int la_GenericTopPanelProcessing(laOperator* a, laEvent* e);
  1485. int OPMOD_FinishOnData(laOperator* a, laEvent* e);
  1486. int la_UiOperatorExists(void *inst);
  1487. int laOperatorExistsT(laOperatorType* at);
  1488. int laOperatorExists(const char* ID);
  1489. int laInvokeUi(laOperator *From, char *ID, laEvent *e, void *inst, laListHandle *Locals, int IgnoreLocals);
  1490. int laInvokeUiP(laOperator *From, laOperatorType *at, laEvent *e, void *inst, laListHandle *Locals, int IgnoreLocals);
  1491. int laInvoke(laOperator *From, char *ID, laEvent *e, laPropPack *This, char *args, char *args2);
  1492. int laInvokeP(laOperator *From, laOperatorType *at, laEvent *e, laPropPack *This, char *args, char *args2);
  1493. int laInvokePCreateThis(laOperator *From, laOperatorType *at, laEvent *e, laPropPack *OrigionalThis, void *FromInstance, char *args, char *args2);
  1494. void laRequestDelayEvent(real Seconds);
  1495. int la_UiStillInService(void *UiInstance);
  1496. void la_StopUiOperatorService(void *UiInstance);
  1497. void la_StopAllOperators();
  1498. int la_ProcessTextEdit(laEvent *e, laStringEdit *se, laUiItem* ui);
  1499. void laConfirmInt(laOperator *a, int Data, int mode);
  1500. void laConfirmFloat(laOperator *a, real Data, int mode);
  1501. void laConfirmString(laOperator *a, char *Str, int mode);
  1502. int laConfirmSameDataIfAny(laOperator *a);
  1503. void laConfirmUserData(laOperator *a, void *UserData, laConfirmDataDestroyFunc Destroy, int mode);
  1504. int laGetConfirmInt(laOperator *a);
  1505. real laGetConfirmFloat(laOperator *a);
  1506. void laGetConfirmString(laOperator *a, char *buf);
  1507. void *laGetConfirmUserData(laOperator *a);
  1508. //int laInvokeSub(laProp* From, char * ID, laEvent* e, void* inst);
  1509. void laFinalizeOperators();
  1510. int laWaitFor(laOperator *Who, int State);
  1511. void la_PrintOperatorStack();
  1512. void laui_DefaultPanelTitleBar(laUiList *uil, laPropPack *Base, laPropPack *Extra, laUiDefineFunc header);
  1513. void laui_DefaultOperatorPanelTitleBar(laUiList *uil, laPropPack *Base, laPropPack *OperatorInst, laColumn *ExtraColumns, int context);;
  1514. void laui_DefaultSubWindowMenuBarActual(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);;
  1515. void laui_DefaultMenuBarActual(laUiList *uil, laPropPack *pp, laPropPack *actinst, laColumn *extracol, int context);;
  1516. void laui_DefaultMenuBar(laWindow *w);
  1517. void laui_DefaultSubWindowMenuBar(laWindow *w);
  1518. void laui_DefaultPropUiDefine(laUiList *uil, laPropPack *This, laPropPack *OperatorProps, laColumn *UNUSED, int context);;
  1519. int laCopyToClipboard(unsigned char * text);
  1520. extern laUiType *_LA_UI_FIXED_GROUP;
  1521. extern laUiType *_LA_UI_TAB;
  1522. extern laUiType _LA_UI_CONDITION; //NO PTR
  1523. extern laUiType _LA_UI_CONDITION_END; //NO PTR
  1524. extern laUiType _LA_UI_CONDITION_ELSE; //NO PTR
  1525. extern laUiType _LA_UI_ROW_BEGIN; //NO PTR
  1526. extern laUiType _LA_UI_ROW_END; //NO PTR
  1527. extern laUiType *_LA_UI_COLLECTION;
  1528. extern laUiType *_LA_UI_COLLECTION_ITEM;
  1529. extern laUiType *_LA_UI_COLLECTION_SELECTOR;
  1530. extern laUiType *_LA_UI_COLLECTION_SINGLE;
  1531. extern laUiType *_LA_UI_BUTTON;
  1532. extern laUiType *_LA_UI_LABEL;
  1533. extern laUiType *_LA_UI_INT;
  1534. extern laUiType *_LA_UI_VALUE_METER;
  1535. extern laUiType *_LA_UI_VALUE_METER_2D;
  1536. extern laUiType *_LA_UI_FLOAT;
  1537. extern laUiType *_LA_UI_FLOAT_COLOR;
  1538. extern laUiType *_LA_UI_FLOAT_COLOR_HCY;
  1539. extern laUiType *_LA_UI_ENUM_SELECTOR;
  1540. extern laUiType *_LA_UI_MENU_ROOT;
  1541. extern laUiType *_LA_UI_CONDITION_TOGGLE;
  1542. extern laUiType *_LA_UI_STRING;
  1543. extern laUiType *_LA_UI_STRING_MULTI;
  1544. extern laUiType *_LA_UI_ALIGN;
  1545. extern laUiType *_LA_UI_CANVAS;
  1546. extern laUiType *_LA_UI_COLUMN_ADJUSTER;
  1547. extern laUiType *_LA_UI_SYMBOL;
  1548. extern laUiType *_LA_UI_COLUMN_VIEWER;
  1549. extern laUiType *_LA_UI_NODE_SOCKET;
  1550. extern laUiType *_LA_UI_HEIGHT_ADJUSTER;
  1551. extern laUiType *_LA_UI_RAW;
  1552. extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_UI;
  1553. extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_UIE;
  1554. extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_P;
  1555. extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_PE;
  1556. extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_BASE;
  1557. extern laUiDescriptor _LA_UI_DESCRIPTOR_REF_ACT;
  1558. extern laUiDefineFunc _LA_SUBPROP_DONT_CARE;
  1559. extern laBoxedTheme *_LA_THEME_PANEL;
  1560. extern laBoxedTheme *_LA_THEME_VALUATOR;
  1561. extern laBoxedTheme *_LA_THEME_BUTTON;
  1562. extern laBoxedTheme *_LA_THEME_STRING;
  1563. extern laBoxedTheme *_LA_THEME_SELECTOR;
  1564. extern laBoxedTheme *_LA_THEME_COLLECTION_SELECTOR;
  1565. extern laBoxedTheme *_LA_THEME_LABEL;
  1566. extern laBoxedTheme *_LA_THEME_TAB;
  1567. extern laBoxedTheme *_LA_THEME_COLLECTION_GROUP;
  1568. extern laBoxedTheme *_LA_THEME_COLLECTION_ITEM;
  1569. extern laBoxedTheme *_LA_THEME_FLOATING_PANEL;
  1570. extern laBoxedTheme *_LA_THEME_3D_VIEW;
  1571. extern laBoxedTheme *_LA_THEME_2D_VIEW;
  1572. extern laBoxedTheme *_LA_THEME_SOCKET;
  1573. extern laProp *_LA_PROP_PANEL;
  1574. extern laProp *_LA_PROP_BLOCK;
  1575. extern laProp *_LA_PROP_WINDOW;
  1576. extern laProp *_LA_PROP_UI_ITEM;
  1577. extern laProp *_LA_PROP_FAILED_ITEM;
  1578. extern laProp *_LA_PROP_TRASH_ITEM;
  1579. extern laProp *_LA_PROP_NODE_GRAPH;
  1580. extern laPropContainer *_LA_PROP_3D_EXTRA;
  1581. extern laPropContainer *_LA_PROP_2D_EXTRA;
  1582. extern laPropContainer *_LA_PROP_FILE_BROWSER;
  1583. extern laProp _P_LA_USE_INSTANCE_ONLY;
  1584. #define _LA_USE_INSTANCE_ONLY (&_P_LA_USE_INSTANCE_ONLY)
  1585. #define LA_CARE_ALL64 (~(0ull))
  1586. #define LA_CARE_ALL32 (~(0ull))
  1587. #define LA_MATCH_INSTANCE (1ull << 63)
  1588. #define LA_IN_USER_PREF (1ull << 62)
  1589. #define LA_IN_LIVE_EDIT (1ull << 61)
  1590. #define LA_IN_PANEL (1ull << 60)
  1591. #define LA_IN_WINDOW (1ull << 59)
  1592. #define LA_IN_LAYOUT (1ull << 58)
  1593. #define LA_USER_THEME (1ull << 63)
  1594. #define LA_USER_THEME_SIZE (1ull << 62)
  1595. #define LA_USER_THEME_COLOR (1ull << 61)
  1596. #define LA_USER_DISPLAY (1ull << 60)
  1597. #define LA_LIVE_PATH (1ull << 63)
  1598. #define LA_LIVE_TYPE (1ull << 62)
  1599. #define LA_LIVE_THEME (1ull << 61)
  1600. #define LA_LIVE_EXTRA (1ull << 60)
  1601. #define LA_WINDOW_INFO (1ull << 63)
  1602. #define LA_LAYOUT_INFO (1ull << 63)
  1603. #define LA_UI_INTERNAL_BUTTON 1
  1604. #define LA_UI_INTERNAL_WATCHER 2
  1605. #define LA_UI_INTERNAL_GROUP 3
  1606. #define LA_UI_INTERNAL_TAB 4
  1607. #define LA_UI_INTERNAL_LABEL 5
  1608. #define LA_UI_INTERNAL_3D_VIEW 6
  1609. #define LA_UI_INTERNAL_2D_VIEW 7
  1610. #define LA_UI_INTERNAL_ADJUSTER 8
  1611. #define LA_UI_INTERNAL_BRACKET_BEGIN 9
  1612. #define LA_UI_INTERNAL_BRACKET_ELSE 10
  1613. #define LA_UI_INTERNAL_FOLDER_BEGIN 11
  1614. #define LA_UI_INTERNAL_BRACKET_END 12
  1615. #define LA_UI_INTERNAL_ALIGNER 13
  1616. #define LA_UI_INTERNAL_MENU 14
  1617. #define LA_UI_INTERNAL_SYMBOL 15
  1618. #define LA_RH0 (MAIN.UiRowHeight)
  1619. #define LA_RH (MAIN.ScaledUiRowHeight)
  1620. #define LA_2RH (MAIN.ScaledUiRowHeight*2)
  1621. #define LA_RH2 ((int)(MAIN.ScaledUiRowHeight/2))
  1622. #define LA_SCROLL_W ((int)(MAIN.ScaledUiRowHeight * 0.67))
  1623. #define LA_SEAM_W ((int)(MAIN.ScaledUiRowHeight * 0.15))