Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add NoHeader() to TableWidget #830

Merged
merged 3 commits into from
Jul 27, 2024
Merged

Conversation

JetSetIlly
Copy link
Contributor

Discussion here:
#829

The SimpleHeader() idea in the first post is too inflexible. This pull request is for the NoHeader() idea from the second post.

when the noHeader flag is set the columns are created as normal by the
Build() function. however the imgui.TableHeadersRow() function is not
called

this means that table columns can be set up in the normal way (widths,
resizeable, etc.) but without the column names being shown and without
the table context menu

if the column headers nned to be shown then the application can draw
them manually as required
Copy link
Collaborator

@gucio321 gucio321 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ifv that works for you i think it is ok. Just a small change in comments pls

TableWidgets.go Outdated
@@ -132,6 +134,12 @@ func (t *TableWidget) FastMode(b bool) *TableWidget {
return t
}

// NoHeader indicates that the column header should not be shown.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add here that "it allows to setup column flags in Columns method" and say something about this method in a comment over Columns method - just for documentation

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Okay. New change committed

Copy link
Collaborator

@gucio321 gucio321 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm
@AllenDang could you take a look and merge

@AllenDang AllenDang merged commit a27dda2 into AllenDang:master Jul 27, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants