# Gtk: How do I resize a window programmatically?

**URL:** <https://discourse.julialang.org/t/gtk-how-do-i-resize-a-window-programmatically/59684>\
**Category:** Visualization\
**Tags:** question\
**Created:** [April 20, 2021, 6:25pm UTC](https://discourse.julialang.org/t/gtk-how-do-i-resize-a-window-programmatically/59684 "2021-04-20T18:25:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![johntrinder](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/johntrinder/32/31783_2.png) [@johntrinder](https://discourse.julialang.org/u/johntrinder)\
**Post date:** [April 20, 2021, 6:25pm UTC](https://discourse.julialang.org/t/gtk-how-do-i-resize-a-window-programmatically/59684/1 "2021-04-20T18:25:04Z")

</div>

In Julia Gtk, how do I resize a window or widget/container programmatically?

---

<div class="post-metadata">

**Author:** ![johntrinder](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/johntrinder/32/31783_2.png) [@johntrinder](https://discourse.julialang.org/u/johntrinder)\
**Post date:** [April 20, 2021, 6:49pm UTC](https://discourse.julialang.org/t/gtk-how-do-i-resize-a-window-programmatically/59684/2 "2021-04-20T18:49:05Z")

</div>

Finally found the answer by examining source code in Gtk.jl  
You do resize!(win, x, y)  
resize! only works on windows, not containers or widgets.

---

<div class="post-metadata">

**Author:** ![OmarElrefaei](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/omarelrefaei/32/43002_2.png) [@OmarElrefaei](https://discourse.julialang.org/u/OmarElrefaei)\
**Post date:** [April 20, 2021, 7:50pm UTC](https://discourse.julialang.org/t/gtk-how-do-i-resize-a-window-programmatically/59684/3 "2021-04-20T19:50:57Z")

</div>

Well, maybe you could help with documenting it them. 😉
