andlabs / andlabs/libui

Adding a uiOrientation enum.

未关闭
#312 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
C
星标
10.9k
派生
612
PR 合并指标
30 天内没有已合并 PR

描述

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);
```

贡献指南

打开贡献指南

评估

这个 Issue 还没有评估数据。

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。