Termux:GUI C/C++ Bindings
Loading...
Searching...
No Matches
types.h
Go to the documentation of this file.
1#pragma once
2
10#include <stdint.h>
11#include <stddef.h>
12#include <stdbool.h>
13
14#ifdef __cplusplus
15extern "C" {
16#endif
17
18
19
20
21
22struct tgui_connection_;
23
27typedef struct tgui_connection_* tgui_connection;
28
29
30
34typedef int32_t tgui_activity;
35
36
37
41typedef int32_t tgui_task;
42
43
44
48typedef int32_t tgui_view;
49
50
54typedef int32_t tgui_remote_layout;
55
56
60typedef int32_t tgui_notification;
61
62
68typedef uint32_t tgui_color;
69
70
71
72
73
77typedef enum {
97
102} tgui_err;
103
104
108typedef enum {
122
123
128typedef enum {
162
163
167typedef enum {
173
177typedef enum {
205
206
207
208
212typedef struct {
216 char country[10];
218 char language[10];
230 double density;
232
233
237typedef enum {
316
317
321
322
323
324
328typedef enum {
349
351 TGUI_MOD_MAX = 1 << 31,
353
354
358typedef enum {
366
367
372typedef enum {
384
385
390typedef enum {
402
403
404
405
412typedef enum {
426
427
428
433typedef struct {
437 float value;
438} tgui_size;
439
440
445typedef enum {
453
454
455
456
461typedef struct {
467
468
473typedef enum {
489
490
495typedef enum {
503
504
509typedef enum {
515
516
521typedef struct {
523 int id;
525 int fd;
527 const uint32_t width;
529 const uint32_t height;
533 void* data;
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
553typedef enum {
567
568
572typedef struct {
574 int x;
576 int y;
578 int id;
580
581
583typedef enum {
584 TGUI_INSET_NONE = 0,
585 TGUI_INSET_NAVIGATION_BAR = 1,
586 TGUI_INSET_STATUS_BAR = 2,
587 TGUI_INSET_BOTH = 3,
588} tgui_inset;
589
590
592typedef enum {
598
599
600
602typedef enum {
603 /*
604 Corresponding to AHARDWAREBUFFER_FORMAT_R8G8B8A8_UNORM.
605 */
606 TGUI_HARDWARE_BUFFER_FORMAT_RGBA8888 = 0,
607 /*
608 Corresponding to AHARDWAREBUFFER_FORMAT_R8G8B8X8_UNORM.
609 */
610 TGUI_HARDWARE_BUFFER_FORMAT_RGBX8888 = 1,
611 /*
612 Corresponding to AHARDWAREBUFFER_FORMAT_R8G8B8_UNORM.
613 */
614 TGUI_HARDWARE_BUFFER_FORMAT_RGB888 = 2,
615 /*
616 Corresponding to AHARDWAREBUFFER_FORMAT_R5G6B5_UNORM.
617 */
618 TGUI_HARDWARE_BUFFER_FORMAT_RGB565 = 3,
620
621
623typedef enum {
624 TGUI_HARDWARE_BUFFER_CPU_NEVER = 0,
625 TGUI_HARDWARE_BUFFER_CPU_RARELY = 1,
626 TGUI_HARDWARE_BUFFER_CPU_OFTEN = 2,
628
629
630
631
632// forward declaration, so the header doesn't need to be included
633typedef struct AHardwareBuffer AHardwareBuffer;
634
636typedef struct {
638 int32_t id;
640 AHardwareBuffer* buffer;
642
643
647typedef enum {
653
654
658typedef struct {
663 union {
672 struct {
674 int id;
676 bool set;
677 } click;
679 struct {
681 int id;
682 } longClick;
684 struct {
686 int id;
688 bool focus;
689 } focus;
691 struct {
693 int id;
701 uint32_t events;
703 uint32_t num_pointers;
705 uint32_t index;
707 uint64_t time;
708 } touch;
710 struct {
712 int id;
714 char* text;
715 } text;
717 struct {
719 int id;
720 } refresh;
722 struct {
724 int id;
727 } selected;
729 struct {
731 int id;
733 int selected;
734 } itemSelected;
736 struct {
738 int id;
740 char* url;
741 } webNavigation;
743 struct {
745 int id;
747 char* url;
749 int code;
750 } webHTTPError;
752 struct {
754 int id;
756 char* url;
757 } webError;
759 struct {
761 int id;
762 } webDestroyed;
764 struct {
766 int id;
769 } webProgress;
771 struct {
773 int id;
775 char* msg;
776 } webConsole;
786 char locale[10];
791 char timezone[10];
793 struct {
795 bool pip;
796 } pip;
798 struct {
800 int rid;
802 int id;
803 } remoteClick;
805 struct {
807 int id;
810 } action;
812 struct {
814 float span;
815 } overlayScale;
817 struct {
821 uint32_t code;
823 uint32_t codePoint;
824 } key;
826 struct {
828 int id;
830 uint64_t timestamp;
831 } frame;
833 struct {
838 } volume;
840 struct {
843 } inset;
845 struct {
847 int id;
849 uint32_t width;
851 uint32_t height;
852 } surfaceChanged;
854 double _dummy[20];
855 };
856} tgui_event;
857
858
859
860
861
862
863#ifdef __cplusplus
864}
865#endif
Provides information on the current device and Activity configuration.
Definition: types.h:212
bool dark_mode
Whether dark mode is enabled. Always false on Android < 10.
Definition: types.h:214
tgui_orientation orientation
The current Activity orientation. Only TGUI_ACTIVITY_LANDSCAPE, TGUI_ACTIVITY_REVERSE_LANDSCAPE,...
Definition: types.h:220
int screen_height
The current Activity height in dp.
Definition: types.h:226
bool keyboard_hidden
Whether the soft keyboard is currently shown.
Definition: types.h:222
int screen_width
The current Activity width in dp.
Definition: types.h:224
double density
The display density, such that screenwidth * density = screenwidth_in_px.
Definition: types.h:230
double font_scale
The current font scale.
Definition: types.h:228
A shared memory buffer for images.
Definition: types.h:521
void * data
The buffer data mapped in memory. MAP_FAILED (from <sys/mman.h>) indicates the buffer is deleted.
Definition: types.h:533
const tgui_buffer_format format
The buffer format. Determines the color channels, their order and the bytes per pixel.
Definition: types.h:531
int id
The buffer id for using the buffer with the plugin. -1 indicates the buffer is deleted.
Definition: types.h:523
int fd
The buffer file descriptor used for mapping the buffer. -1 indicates the buffer is deleted.
Definition: types.h:525
const uint32_t width
The width in pixels.
Definition: types.h:527
const uint32_t height
The height in pixels.
Definition: types.h:529
Represents an event send from the plugin. A union is used so that all events can still have a single ...
Definition: types.h:658
int progress
The progress of the site loading in percent.
Definition: types.h:768
int id
The id of the View.
Definition: types.h:674
tgui_activity_configuration configuration
Valid for TGUI_EVENT_CONFIG.
Definition: types.h:670
tgui_activity activity
Most events are specific to an Activity. If the event belongs to an Activity, this field isn't -1.
Definition: types.h:662
uint32_t codePoint
The unicode code point.
Definition: types.h:823
char * text
The new text of the TextView.
Definition: types.h:714
int code
The HTTP error code.
Definition: types.h:749
tgui_touch_pointer ** pointers
Definition: types.h:699
int selected
The id of the selected RadioButton.
Definition: types.h:726
bool released
Whether the button is pressed or released. Multiple repeating events come for a long press.
Definition: types.h:837
uint32_t width
The new width of the Surface.
Definition: types.h:849
int action
The index of the action, starting at 0.
Definition: types.h:809
char * msg
The console message.
Definition: types.h:775
tgui_inset current_inset
The system insets (bars) that are now showing.
Definition: types.h:842
uint32_t index
index of the pointer added or removed.
Definition: types.h:705
bool volume_up
Whether the event is for the up or down volume button.
Definition: types.h:835
uint32_t num_pointers
Number of pointers for each event in the pointers array.
Definition: types.h:703
tgui_key_modifier mod
The active modifiers.
Definition: types.h:819
bool airplane
The current state of airplane mode. Valid for TGUI_EVENT_AIRPLANE.
Definition: types.h:781
tgui_touch_action action
The type of touch event.
Definition: types.h:695
bool focus
Whether the View now has focus or not.
Definition: types.h:688
bool pip
The current state of picture-in-picture mode.
Definition: types.h:795
uint32_t events
The number of batched move events (size of the first dimension of the pointers array).
Definition: types.h:701
uint64_t timestamp
The timestamp of the frame.
Definition: types.h:830
uint32_t height
The new height of the Surface.
Definition: types.h:851
int rid
The id of the remote layout.
Definition: types.h:800
char * url
The URL that was tried to navigate to.
Definition: types.h:740
bool set
For CheckBox, Switch and ToggleButton.
Definition: types.h:676
float span
The new distance between the 2 pointers.
Definition: types.h:814
bool finishing
Whether the Activity is finishing. Valid for: TGUI_EVENT_PAUSE, TGUI_EVENT_STOP and TGUI_EVENT_DESTR...
Definition: types.h:668
uint32_t code
The Android key code.
Definition: types.h:821
uint64_t time
Timestamp of the event.
Definition: types.h:707
tgui_event_type type
The event type specifies which entry in the union is valid.
Definition: types.h:660
Wrapper for AHardwareBuffer.
Definition: types.h:636
AHardwareBuffer * buffer
The actual AHardwareBuffer.
Definition: types.h:640
int32_t id
The buffer id in the plugin.
Definition: types.h:638
A value in a size unit.
Definition: types.h:433
float value
The value.
Definition: types.h:437
tgui_size_unit unit
The measurement unit.
Definition: types.h:435
A single pointer of a touch event.
Definition: types.h:572
int y
The y coordinate in the View.
Definition: types.h:576
int id
The pointer id. Is guaranteed to stay the same for as long as the pointer is down.
Definition: types.h:578
int x
The x coordinate in the View.
Definition: types.h:574
Defines a View's size.
Definition: types.h:461
tgui_size value
The size, when TGUI_VIEW_SIZE is used as the type.
Definition: types.h:465
tgui_view_size_type type
The size specifier.
Definition: types.h:463
tgui_event_type
All possible event types.
Definition: types.h:237
@ TGUI_EVENT_AIRPLANE
Send when the airplane mode changes.
Definition: types.h:283
@ TGUI_EVENT_WEBVIEW_CONSOLE
Send when Javascript tries to print to the console in a WebView.
Definition: types.h:281
@ TGUI_EVENT_WEBVIEW_PROGRESS
Send when the loading progress in a WebView updates.
Definition: types.h:279
@ TGUI_EVENT_WEBVIEW_DESTROYED
Send when a WebView renderer was destroyed by the system, resulting in the corresponding WebView bein...
Definition: types.h:277
@ TGUI_EVENT_SELECTED
Send when a RadioButton in a RadioGroup has been selected.
Definition: types.h:265
@ TGUI_EVENT_VOLUME
A volume button press was intercepted.
Definition: types.h:311
@ TGUI_EVENT_WEBVIEW_ERROR
Send when a WebView encounters an internal error when fetching a resource, like a SSL error loss of c...
Definition: types.h:275
@ TGUI_EVENT_CREATE
Send when an Activity is created. See the Android documentation for Activity lifecycle for more infor...
Definition: types.h:239
@ TGUI_EVENT_WEBVIEW_NAVIGATION
Send when Javascript or the user tries to navigate to a different page in a WebView.
Definition: types.h:271
@ TGUI_EVENT_WEBVIEW_HTTP_ERROR
Send when a WebView encounters a HTTP error when fetching a resource.
Definition: types.h:273
@ TGUI_EVENT_CLICK
Send when a View is clicked.
Definition: types.h:253
@ TGUI_EVENT_NOTIFICATION_ACTION
Send when a notification action is clicked.
Definition: types.h:303
@ TGUI_EVENT_KEY
A key was pressed when an ImageView or GLSurfaceView with soft keyboard support was focused.
Definition: types.h:307
@ TGUI_EVENT_SCREEN_OFF
Send when the screen is turned off.
Definition: types.h:289
@ TGUI_EVENT_RESUME
Send when an Activity is resumed. See the Android documentation for Activity lifecycle for more infor...
Definition: types.h:243
@ TGUI_EVENT_STOP
Send when an Activity is stopped. See the Android documentation for Activity lifecycle for more infor...
Definition: types.h:247
@ TGUI_EVENT_BACK
Send when the user presses the back button.
Definition: types.h:269
@ TGUI_EVENT_NOTIFICATION_DISMISSED
Send when a notification is swiped away by the user.
Definition: types.h:301
@ TGUI_EVENT_TEXT
Send when the text of a TextView changes.
Definition: types.h:261
@ TGUI_EVENT_OVERLAY_SCALE
Send when a scale gesture was made on an overlay Activity.
Definition: types.h:305
@ TGUI_EVENT_ITEM_SELECTED
Send when an option is selected in a Spinner or a tab in a TabLayout.
Definition: types.h:267
@ TGUI_EVENT_LONG_CLICK
Send when pressing and holding a View.
Definition: types.h:255
@ TGUI_EVENT_REMOTE_CLICK
Send when a click is registered in a remote layout.
Definition: types.h:297
@ TGUI_EVENT_FRAME_COMPLETE
A SurfaceView has completed rendering a frame.
Definition: types.h:309
@ TGUI_EVENT_TIMEZONE
Send when the timezone changes.
Definition: types.h:287
@ TGUI_EVENT_SCREEN_ON
Send when the screen is turned on.
Definition: types.h:291
@ TGUI_EVENT_PIP
Send when an Activity enters or loaves picture-in-picture mode.
Definition: types.h:295
@ TGUI_EVENT_CONFIG
Send when the configuration for an activity changes, i.e. because the Activity is rotated or dark mod...
Definition: types.h:251
@ TGUI_EVENT_SURFACE_CHANGED
The Surface of a SurfaceView changed size.
Definition: types.h:315
@ TGUI_EVENT_TOUCH
Send when a view is touched.
Definition: types.h:259
@ TGUI_EVENT_PAUSE
Send when an Activity is paused. See the Android documentation for Activity lifecycle for more inform...
Definition: types.h:245
@ TGUI_EVENT_USER_LEAVE_HINT
Send when the user leaves an Activity.
Definition: types.h:293
@ TGUI_EVENT_FOCUS
Send when a View gains focus.
Definition: types.h:257
@ TGUI_EVENT_DESTROY
Send when an Activity is destroyed. See the Android documentation for Activity lifecycle for more inf...
Definition: types.h:249
@ TGUI_EVENT_START
Send when an Activity is started. See the Android documentation for Activity lifecycle for more infor...
Definition: types.h:241
@ TGUI_EVENT_REFRESH
Send when a refresh is triggered on a SwipeRefreshLayout.
Definition: types.h:263
@ TGUI_EVENT_LOCALE
Send when the locale changes.
Definition: types.h:285
@ TGUI_EVENT_INSET
The inset status of an Activity changed (status or navigation bar).
Definition: types.h:313
@ TGUI_EVENT_NOTIFICATION
Send when a notification is clicked.
Definition: types.h:299
@ TGUI_EVENT_TYPE_MAX
Maximum value for future binary compatibility.
Definition: types.h:319
struct tgui_connection_ * tgui_connection
Represents a connection to the Termux:GUI plugin.
Definition: types.h:27
tgui_view_visibility
All possible View visibility states.
Definition: types.h:358
@ TGUI_VIS_VISIBLE
Completely visible.
Definition: types.h:360
@ TGUI_VIS_GONE
Invisible and takes up no space in the layout.
Definition: types.h:364
@ TGUI_VIS_HIDDEN
Invisible, but takes up it's space in the layout.
Definition: types.h:362
int32_t tgui_task
Represents an Android Task.
Definition: types.h:41
int32_t tgui_notification
Represents a notification.
Definition: types.h:60
tgui_inset
The types of insets of an Activity that can be shown or hidden.
Definition: types.h:583
tgui_edit_text_type
The types an EditText can be. See the Android documentation for more information.
Definition: types.h:177
@ TGUI_EDIT_TEXT_NUMBER_PASSWORD
Password number input.
Definition: types.h:195
@ TGUI_EDIT_TEXT_TIME
Time input.
Definition: types.h:187
@ TGUI_EDIT_TEXT_PHONE
Phone number input.
Definition: types.h:183
@ TGUI_EDIT_TEXT_NUMBER_SIGNED
Signed number input.
Definition: types.h:197
@ TGUI_EDIT_TEXT_DATE
Date input.
Definition: types.h:185
@ TGUI_EDIT_TEXT_TEXT_PASSWORD
Password input.
Definition: types.h:203
@ TGUI_EDIT_TEXT_NUMBER
Number input.
Definition: types.h:191
@ TGUI_EDIT_TEXT_TEXT
Normal text input.
Definition: types.h:179
@ TGUI_EDIT_TEXT_NUMBER_DECIMAL_SIGNED
Signed decimal number input.
Definition: types.h:199
@ TGUI_EDIT_TEXT_TEXT_EMAIL_ADDRESS
Email address input.
Definition: types.h:201
@ TGUI_EDIT_TEXT_NUMBER_DECIMAL
Decimal number input.
Definition: types.h:193
@ TGUI_EDIT_TEXT_TEXT_MULTILINE
Multiline text input.
Definition: types.h:181
@ TGUI_EDIT_TEXT_DATETIME
Date and time input.
Definition: types.h:189
int32_t tgui_activity
Represents an Android Activity.
Definition: types.h:34
tgui_key_modifier
All supported key modifiers.
Definition: types.h:328
@ TGUI_MOD_LCTRL
Left ctrl pressed.
Definition: types.h:336
@ TGUI_MOD_NUM_LOCK
Num lock pressed.
Definition: types.h:348
@ TGUI_MOD_MAX
Maximum modifier value, for future binary compatibility.
Definition: types.h:351
@ TGUI_MOD_RSHIFT
Right shift pressed.
Definition: types.h:334
@ TGUI_MOD_NONE
No modifier pressed.
Definition: types.h:330
@ TGUI_MOD_CAPS_LOCK
Caps lock pressed.
Definition: types.h:344
@ TGUI_MOD_RCTRL
Right ctrl pressed.
Definition: types.h:338
@ TGUI_MOD_LSHIFT
Left shift pressed.
Definition: types.h:332
@ TGUI_MOD_ALT
Alt pressed.
Definition: types.h:340
@ TGUI_MOD_ALT_GR
Alt gr pressed.
Definition: types.h:346
@ TGUI_MOD_FN
Fn pressed.
Definition: types.h:342
int32_t tgui_remote_layout
Represents a RemoteView layout.
Definition: types.h:54
tgui_hardware_buffer_cpu_frequency
How often the CPU will access the buffer.
Definition: types.h:623
tgui_buffer_format
Formats for shared image buffers.
Definition: types.h:509
@ TGUI_BUFFER_FORMAT_MAX
The maximum buffer format, for future binary compatibility.
Definition: types.h:513
@ TGUI_BUFFER_FORMAT_ARGB8888
The shared buffer wil be in ARGB8888 format.
Definition: types.h:511
tgui_surface_view_dimension_mismatch
Definition: types.h:647
@ TGUI_MISMATCH_STICK_TOPLEFT
The buffer is attached at the top/left edge of the SurfaceView.
Definition: types.h:649
@ TGUI_MISMATCH_CENTER_AXIS
The buffer is centered on the axis.
Definition: types.h:651
tgui_grid_alignment
The View alignment in a GridLayout.
Definition: types.h:473
@ TGUI_GRID_CENTER
Align to cell center.
Definition: types.h:475
@ TGUI_GRID_RIGHT
Align to cell right.
Definition: types.h:483
@ TGUI_GRID_LEFT
Align to cell left.
Definition: types.h:481
@ TGUI_GRID_TOP
Align to cell top.
Definition: types.h:477
@ TGUI_GRID_BASELINE
Align to cell the baseline.
Definition: types.h:485
@ TGUI_GRID_FILL
Fill the whole cell.
Definition: types.h:487
@ TGUI_GRID_BOTTOM
Align to cell bottom.
Definition: types.h:479
tgui_inset_behaviour
How the insets of an Activity will behave to user interaction.
Definition: types.h:592
@ TGUI_INSET_BEHAVIOUR_TRANSIENT
Make the insets temporarily and transparently visible on a swipe from the edge.
Definition: types.h:596
@ TGUI_INSET_BEHAVIOUR_DEFAULT
Make the insets visible again on a swipe from the edge.
Definition: types.h:594
int32_t tgui_view
Represents an Android View.
Definition: types.h:48
tgui_importance
The importance of a notification.
Definition: types.h:390
@ TGUI_IMP_MAX
Maximum importance.
Definition: types.h:400
@ TGUI_IMP_MIN
Minimal importance, silent notification.
Definition: types.h:394
@ TGUI_IMP_HIGH
High importance.
Definition: types.h:398
@ TGUI_IMP_LOW
Low importance.
Definition: types.h:396
@ TGUI_IMP_DEFAULT
Use the default importance.
Definition: types.h:392
tgui_activity_type
All possible types of Activities.
Definition: types.h:108
@ TGUI_ACTIVITY_NORMAL
Standard fullscreen Activity.
Definition: types.h:110
@ TGUI_ACTIVITY_OVERLAY
The Activity will be started as an overlay over everything else.
Definition: types.h:120
@ TGUI_ACTIVITY_LOCKSCREEN
The activity will show on the lockscreen.
Definition: types.h:118
@ TGUI_ACTIVITY_PIP
The Activity is started in picture-in-picture mode.
Definition: types.h:116
@ TGUI_ACTIVITY_DIALOG_CANCELOUTSIDE
Activity is started in a dialog, but touching outside the dialog cancels it.
Definition: types.h:114
@ TGUI_ACTIVITY_DIALOG
Activity is started in a dialog.
Definition: types.h:112
tgui_size_unit
All supported size units.
Definition: types.h:412
@ TGUI_UNIT_PX
pixels unit
Definition: types.h:418
@ TGUI_UNIT_MM
millimeters unit
Definition: types.h:420
@ TGUI_UNIT_DP
density-pixels unit
Definition: types.h:414
@ TGUI_UNIT_PT
points unit
Definition: types.h:424
@ TGUI_UNIT_SP
scale-pixels unit
Definition: types.h:416
@ TGUI_UNIT_IN
inches unit
Definition: types.h:422
tgui_hardware_buffer_format
Available hardware buffer formats.
Definition: types.h:602
uint32_t tgui_color
An RGBA8888 color code.
Definition: types.h:68
tgui_direction
The direction for margins and paddings.
Definition: types.h:372
@ TGUI_DIR_BOTTOM
Set for the bottom.
Definition: types.h:380
@ TGUI_DIR_LEFT
Set for the left.
Definition: types.h:378
@ TGUI_DIR_TOP
Set for the top.
Definition: types.h:376
@ TGUI_DIR_ALL
All set for directions.
Definition: types.h:374
@ TGUI_DIR_RIGHT
Set for the right.
Definition: types.h:382
tgui_orientation
Specifies the orientation you can set an Activity to.
Definition: types.h:128
@ TGUI_ORIENTATION_REVERSE_LANDSCAPE
Lock the orientation to the opposite landscape mode.
Definition: types.h:146
@ TGUI_ORIENTATION_NOSENSOR
Ignore the orientation sensor.
Definition: types.h:142
@ TGUI_ORIENTATION_FULL_USER
Respect the users option to lock the rotation, but allow all 4 possible rotations if enabled.
Definition: types.h:136
@ TGUI_ORIENTATION_UNSPECIFIED
Lets the system choose the orientation.
Definition: types.h:130
@ TGUI_ORIENTATION_SENSOR
Determine the orientation with the sensor.
Definition: types.h:150
@ TGUI_ORIENTATION_SENSOR_PORTRAIT
Use portrait, but can be changed with the sensor.
Definition: types.h:154
@ TGUI_ORIENTATION_USER
Use the users preferred orientation.
Definition: types.h:156
@ TGUI_ORIENTATION_SENSOR_LANDSCAPE
Use landscape, but can be changed with the sensor.
Definition: types.h:152
@ TGUI_ORIENTATION_REVERSE_PORTRAIT
Lock the orientation to the opposite portrait mode.
Definition: types.h:148
@ TGUI_ORIENTATION_BEHIND
The same orientation as the Activity behind in the Activity stack.
Definition: types.h:132
@ TGUI_ORIENTATION_LOCKED
Lock the orientation to the current one.
Definition: types.h:140
@ TGUI_ORIENTATION_LANDSCAPE
Lock the orientation to landscape.
Definition: types.h:138
@ TGUI_ORIENTATION_PORTRAIT
Lock the orientation to portrait.
Definition: types.h:144
@ TGUI_ORIENTATION_USER_PORTRAIT
Use portrait, but can be changed with the sensor if the user allowed it.
Definition: types.h:160
@ TGUI_ORIENTATION_FULL_SENSOR
Orientation determined by the orientation sensor. All 4 orientations are possible.
Definition: types.h:134
@ TGUI_ORIENTATION_USER_LANDSCAPE
Use landscape, but can be changed with the sensor if the user allowed it.
Definition: types.h:158
tgui_touch_action
Possible causes for touch events.
Definition: types.h:553
@ TGUI_TOUCH_POINTER_DOWN
Send when an additional pointer touches.
Definition: types.h:559
@ TGUI_TOUCH_MOVE
Send when pointers have been moved.
Definition: types.h:565
@ TGUI_TOUCH_CANCEL
Like TOUCH_UP, but the gesture was cancelled.
Definition: types.h:563
@ TGUI_TOUCH_DOWN
Send when the first pointer touches.
Definition: types.h:555
@ TGUI_TOUCH_POINTER_UP
Send when an additional pointer goes up.
Definition: types.h:561
@ TGUI_TOUCH_UP
Send when the last pointer goes up.
Definition: types.h:557
tgui_err
Status codes for all functions in the library.
Definition: types.h:77
@ TGUI_ERR_CONNECTION_LOST
The connection to the plugin was lost. All further operations on this connection except destroy opera...
Definition: types.h:83
@ TGUI_ERR_VIEW_INVALID
The View used was invalid or of a wrong type.
Definition: types.h:94
@ TGUI_ERR_SYSTEM
An error occurred in the system library. Check errno to get the exact error.
Definition: types.h:81
@ TGUI_ERR_MAX
Maximum value for future binary compatibility.
Definition: types.h:99
@ TGUI_ERR_NOMEM
There is not enough memory to complete an operation.
Definition: types.h:90
@ TGUI_ERR_ACTIVITY_DESTROYED
The Activity the function tried to act on no longer exists.
Definition: types.h:85
@ TGUI_ERR_MIN
Minimum value for future binary compatibility.
Definition: types.h:101
@ TGUI_ERR_MESSAGE
Definition: types.h:88
@ TGUI_ERR_API_LEVEL
The Android API level is too low for the function.
Definition: types.h:96
@ TGUI_ERR_OK
Operation was successful.
Definition: types.h:79
@ TGUI_ERR_EXCEPTION
An exception was thrown in the C++ part that could not be mapped to other errors.
Definition: types.h:92
tgui_gravity
Gravity of text in a TextView.
Definition: types.h:495
@ TGUI_GRAV_RIGHTBOTTOM
Right or bottom.
Definition: types.h:501
@ TGUI_GRAV_CENTER
Center.
Definition: types.h:497
@ TGUI_GRAV_LEFTTOP
Top or left.
Definition: types.h:499
tgui_activity_input_mode
Determines how an Activity reacts when the soft keyboard is opened.
Definition: types.h:167
@ TGUI_ACTIVITY_INPUT_MODE_PAN
Pan the Activity up to make room for the soft keyboard.
Definition: types.h:169
@ TGUI_ACTIVITY_INPUT_MODE_RESIZE
Resizes the Activity to fit the smaller size.
Definition: types.h:171
tgui_view_size_type
The types with which a View size can be specified.
Definition: types.h:445
@ TGUI_VIEW_MATCH_PARENT
Match the parent view size.
Definition: types.h:447
@ TGUI_VIEW_SIZE
Use the provided size.
Definition: types.h:451
@ TGUI_VIEW_WRAP_CONTENT
Match the content size.
Definition: types.h:449