Advertisement
captmicro

Flagship GUI Lua environment

Jul 23rd, 2013
390
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.72 KB | None | 0 0
  1. color = Color(int red, int green, int blue, int alpha)
  2. color
  3. .red [int]
  4. .green [int]
  5. .blue [int]
  6. .alpha [int]
  7.  
  8.  
  9. point = Point(int x, int y)
  10. point
  11. .x [int]
  12. .y [int]
  13.  
  14.  
  15. size = Size(int w, int h)
  16. size
  17. .w [int]
  18. .h [int]
  19.  
  20.  
  21. image = Image(string imgdata)
  22. image
  23. .Resize(Size size)
  24. .Crop(Point topleft, Point bottomright)
  25.  
  26.  
  27. Align
  28. .Top
  29. .Left
  30. .Center
  31. .Right
  32. .Center
  33. .Left
  34. .Center
  35. .Right
  36. .Bottom
  37. .Left
  38. .Center
  39. .Right
  40.  
  41.  
  42. ClickType
  43. .Press
  44. .LongPress
  45. .Release
  46.  
  47.  
  48. MenuBarButton
  49. .Return
  50. .Home
  51. .Menu
  52.  
  53.  
  54. ToastLocation
  55. .Top
  56. .Center
  57. .Bottom
  58.  
  59.  
  60. PopupType
  61. .OK
  62. .OKCancle
  63.  
  64.  
  65. PopupResult
  66. .OK
  67. .Cancle
  68.  
  69.  
  70. surface
  71. .DrawLine(Point start, Point end, Color color)
  72. .DrawRect(Point topleft, Point bottomright, Color color [, bool outlineonly])
  73. .DrawPoly(Point point1, Point point2, Point point3, ...)
  74. .DrawCircle(Point center, int radius)
  75. .DrawText(Point point, Align align, int size, Color color)
  76. .ScreenWidth
  77. .ScreenHeight
  78.  
  79.  
  80. statusbar
  81. .text [string]
  82. .AddItem(VGUIElement element)
  83. .RemoveItem(VGUIElement element)
  84.  
  85.  
  86. menubar
  87. .callback [function]
  88.  
  89.  
  90. gui
  91. .Create(string name)
  92. .Destroy(VGUIElement element)
  93.  
  94.  
  95. icon = gui.Create("icon")
  96. icon
  97. .image [Image]
  98. .callback [function]
  99.  
  100.  
  101. list = gui.Create("list")
  102. list
  103. .header [string]
  104. .AddItem(string text)
  105. .footer [string]
  106. .callback [function]
  107.  
  108.  
  109. notification = gui.Create("notification")
  110. notification
  111. .text [string]
  112. .callback [function]
  113. .Push()
  114.  
  115.  
  116. toast = gui.Create("toast")
  117. toast
  118. .text [string]
  119. .location [ToastLocation]
  120. .callback [function]
  121. .Push()
  122.  
  123.  
  124. popup = gui.Create("popup")
  125. popup
  126. .title [string]
  127. .text [string]
  128. .type [PopupType]
  129. .callback [function]
  130. .Push()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement