andlabs / andlabs/libui

Adding a uiOrientation enum.

Offen
#312 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
C
Sterne
10.9k
Forks
612
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

This enum would represent the orientation of control or other object, and could look like this:

```c
_UI_ENUM(uiOrientation) {
uiOrientationHorizontal,
uiOrientationVertical,
};
```

This would remove the need of separate methods for creation of these controls. For example, in `ui.h`, both sets of creation methods for `uiSeparator` and `uiBox` could be turned into one method for each, both looking something like:

```c
_UI_EXTERN uiBox uiNewBox(uiOrientation o);
_UI_EXTERN uiSeparator uiNewSeparator(uiOrientation o);
```

Beitragsleitfaden

Beitragsleitfaden öffnen

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.