You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -730,51 +761,10 @@ Shortcut to create `Percent` object.
730
761
731
762
</details>
732
763
733
-
## 4. Theme
764
+
## 6. Custom Widget
734
765
735
766
<detailsopen>
736
-
<summary>Theme</summary>
737
-
738
-
Defined in "src/libs/beGUI/beTheme.lua". Widget classes will lookup for image resources, client area, content offset, fonts, colors and all other appearance config from it.
739
-
740
-
</details>
741
-
742
-
## 5. Tweening
743
-
744
-
<detailsopen>
745
-
<summary>Tweening</summary>
746
-
747
-
beGUI is integrated with a tweening lib adapted from [kikito/tween.lua](https://github.com/kikito/tween.lua), which allows to create tweening animations.
748
-
749
-
### beGUI.Tween
750
-
751
-
**Model: `require 'libs/beGUI/beGUI'`**
752
-
753
-
* beGUI.`Tween.new(duration, subject, target, easing)`: constructs a `Tween` object
754
-
*`duration`: the duration in seconds
755
-
*`subject`: the tweening subject
756
-
*`target`: the tweening target
757
-
*`easing`: the easing function
758
-
759
-
*`tween:set(clock)`: sets the `Tween` object to a specific clock point
760
-
*`clock`: the click time point
761
-
* returns `true` for success, otherwise `false`
762
-
*`tween:reset()`: resets the `Tween` object
763
-
* returns `true` for success, otherwise `false`
764
-
*`tween:update(delta)`: updates the `Tween` object with a specific delta time in seconds
765
-
* returns `true` for success, otherwise `false`
766
-
767
-
*`tween:on('changed', function (sender) end)`: registers an event which will be triggered when the `Tween` has been updated
768
-
* returns `self`
769
-
*`tween:on('completed', function (sender) end)`: registers an event which will be triggered when the `Tween` has completed
770
-
* returns `self`
771
-
772
-
</details>
773
-
774
-
## 6. Custom Widgets
775
-
776
-
<detailsopen>
777
-
<summary>Custom Widgets</summary>
767
+
<summary>Custom Widget</summary>
778
768
779
769
There are two ways to customize your own `Widget`, one is to use the beWidget.`Custom``Widget`, the other is to write your own `Widget` class.
780
770
@@ -849,6 +839,50 @@ local MyWidget = beClass.class({
849
839
850
840
</details>
851
841
842
+
## 7. Theme
843
+
844
+
<detailsopen>
845
+
<summary>Theme</summary>
846
+
847
+
Defined in "src/libs/beGUI/beTheme.lua". Widget classes will lookup for image resources, client area, content offset, fonts, colors and all other appearance config from it.
848
+
849
+
</details>
850
+
851
+
## 8. Tweening
852
+
853
+
<detailsopen>
854
+
<summary>Tweening</summary>
855
+
856
+
beGUI is integrated with a tweening lib adapted from [kikito/tween.lua](https://github.com/kikito/tween.lua), which allows to create tweening animations.
857
+
858
+
### beGUI.Tween
859
+
860
+
**Model: `require 'libs/beGUI/beGUI'`**
861
+
862
+
* beGUI.`Tween.new(duration, subject, target, easing)`: constructs a `Tween` object
863
+
*`duration`: the duration in seconds
864
+
*`subject`: the tweening subject
865
+
*`target`: the tweening target
866
+
*`easing`: the easing function
867
+
868
+
*`tween:reset()`: resets the `Tween` object
869
+
* returns `self`
870
+
*`tween:set(clock)`: sets the `Tween` object to a specific clock point
871
+
*`clock`: the click time point
872
+
* returns `true` for success, otherwise `false`
873
+
*`tween:update(delta)`: updates the `Tween` object with a specific delta time in seconds
874
+
* returns `true` for success, otherwise `false`
875
+
876
+
*`tween:on('changed', function (sender) end)`: registers an event which will be triggered when the `Tween` has been updated
877
+
* returns `self`
878
+
*`tween:on('completed', function (sender) end)`: registers an event which will be triggered when the `Tween` has completed
879
+
* returns `self`
880
+
*`tween:off(event)`: unregisters the handlers of the specific event
0 commit comments