Smallest possible window?

What is the smallest possible window you can create in Xojo that you can still move around in a Windows 7 or Windows 10 environment?

Time was on a Mac you could shrink any window to just its top bar by double clicking on it and then expand it by double clicking again, which I thought was really cool. OK, you couldn’t tell from the bar which window it was, but if you had several on screen and you expanded the wrong one you just shrank it again.

Being forced to have all the Windows paraphernalia means the windows you can practically create are getting bigger. I like to have tiny windows I can move around that do simple tasks like keep a check of my Ip address.

I’ve been playing with containers and I would love to be able to create a movable horizontal or vertical strip I could move around that could morph into a login window, say, when double clicked, then morph into other shapes and sizes of window by loading up different containers.

Use a plain box window with no menu.

I’ll have a look at that in the reference manual - could that be the default window for the app?

Sure, just set that in the IDE.

You will have to manage the moving around, though.

Hi Michel that was helpful and I see what you mean about handling the moving around.
But even a plain box has two menu items and is about one inch square at least. I know it sounds daft but is there any way to make a window even smaller and to cover up the menu items with a graphic or something. I know this goes against the grain of windows-type interfaces, but if I don’t want the menu bar and If I want to have a window half a centimetre by 10 centimetres covered by a graphic I don’t see why I can’t have one! Is it possible?

Oh, I just looked back and saw you wrote a plain box “with no menu” I missed that. I’ll have to check it out again when I get back home. Sorry!

Under Windows 10 the pain box still has a small 6 points or so white bar.

Here is what to put in the Open event to make it right :

Sub Open() Const WS_BORDER = &H800000 Const WS_DLGFRAME = &H400000 Const GWL_STYLE = -16 Declare Function SetWindowLong Lib "user32" Alias "SetWindowLongA" (hwnd As Integer, nIndex As Integer, dwNewLong As Integer) As Integer dim rien as integer = SetWindowLong(self.handle, GWL_STYLE, WS_BORDER) End Sub

Then the window can be 36 points high minimum.

As far as UI design goes today, the guidelines are quite different from what they were a few years ago. I’ll risk saying as long as it is easy to use and clean, anything is permitted. Also, GUI is much closer to web design. You may want to have a look here :

OK, I just got back and it was quite interesting. In the IDE, I found I could set width, height, minimum height and minimum width all to very small numbers, including zero so long as the Menu Bar was set to None and all the buttons were off (except the resizeable button, which I would need)

But when I ran the program, I couldn’t resize the height to less than about 1cm and I couldn’t resize the width to less than about 3-4cms.

Your comments today take me into uncharted seas for me, but I’ll have a look tomorrow. Many thanks

Make sure to set the minimum height to the same value as height.