Skip to content

button positioning #1598

Answered by vyrjana
jkissi asked this question in Support
Feb 13, 2022 · 1 comments · 1 reply
Discussion options

You must be logged in to vote

You can use group or add_group. The former is more convenient since you can do the following with it:

# dpg is imported somewhere earlier in the file as follows:
# import dearpygui.dearpygui as dpg

with dpg.group(horizontal=True):
  dpg.add_button(label="Button on the left")
  dpg.add_button(label="Button on the right")

Note the horizontal=True argument when calling group.

The official demo has more examples of how to use group (and add_group).

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@jkissi
Comment options

Answer selected by hoffstadt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Support
Labels
None yet
2 participants