Wednesday, May 1, 2024
 Popular · Latest · Hot · Upcoming
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 7021  / 2 Years ago, wed, january 5, 2022, 11:46:31

Trying to create the framework for a calculator.



I add the window
I add the vbox using 2 boxes. 1 for the display, the other for the buttons
When I add 1 button it fills the entire panel and I can't resize it.



In visual basic you can just add a button and resize it, or drag and drop anywhere you want.



I just can't figure out how to do it here. Steep learning curve for me.


More From » gtk

 Answers
1

GTK+ uses box-based sizing, just like CSS and other modern tools. Also, a VBox will have all its children oriented vertically. You won't be able to add anything to the right.



You can use the GtkLayout for absolute positioning, or a GtkGrid to create a grid-based layout (which is appropriate for calculator).


[#32737] Wednesday, January 5, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
pantkie

Total Points: 209
Total Questions: 112
Total Answers: 138

Location: Venezuela
Member since Sat, Apr 24, 2021
3 Years ago
;