Muffin: change window min dimension

Please post suggestions for improvement of Cinnamon here
https://github.com/linuxmint/Cinnamon
Post Reply
tobian
Level 1
Level 1
Posts: 6
Joined: Wed Jun 27, 2018 1:19 pm

Muffin: change window min dimension

Post by tobian » Tue Oct 30, 2018 1:28 pm

Greetings,

When i resize a window, it won't go beyond a certain point. I would like to change this behaviour.

Someone know where i can retrieve and edit these settings? Are they hard-coded in Muffin itself?

User avatar
smurphos
Level 8
Level 8
Posts: 2246
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Muffin: change window min dimension

Post by smurphos » Tue Oct 30, 2018 2:25 pm

It's hard-coded in certain apps not in the Window manager itself.

tobian
Level 1
Level 1
Posts: 6
Joined: Wed Jun 27, 2018 1:19 pm

Re: Muffin: change window min dimension

Post by tobian » Tue Oct 30, 2018 2:38 pm

Actually, under Kwin, the same apps can be resized according to my rules.

User avatar
smurphos
Level 8
Level 8
Posts: 2246
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Muffin: change window min dimension

Post by smurphos » Tue Oct 30, 2018 2:40 pm

But Kwin isn't Muffin is it? Muffin is respecting the size requirements hardcoded into the apps to make sure all the menu buttons are always visible.

Which apps are you having trouble with?

tobian
Level 1
Level 1
Posts: 6
Joined: Wed Jun 27, 2018 1:19 pm

Re: Muffin: change window min dimension

Post by tobian » Tue Oct 30, 2018 3:00 pm

smurphos wrote:
Tue Oct 30, 2018 2:40 pm
But Kwin isn't Muffin is it? Muffin is respecting the size requirements hardcoded into the apps to make sure all the menu buttons are always visible.
Well, sure is not! I was trying to say that it doesn't happen with Kwin, nvm then, didn't know about the policy of Muffin.

So my question now is: can i force Muffin to apply my rules on windows?

I have to launch multiple istance of Xviewer and resize the windows so that they can fit the space according to my will, it's for a project at school.

User avatar
smurphos
Level 8
Level 8
Posts: 2246
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Muffin: change window min dimension

Post by smurphos » Tue Oct 30, 2018 3:21 pm

I think you need to more specific about what you are not able to do?

Muffin supports basic tiling - Window Tiling in the settings menu. Free form resizing is normally a case of grabbing a corner or edge.

You can use the command line tool wmctrl to automate window size and position if that is what you are after. So a script to launch multiple instances and fit them to specified dimensions.

tobian
Level 1
Level 1
Posts: 6
Joined: Wed Jun 27, 2018 1:19 pm

Re: Muffin: change window min dimension

Post by tobian » Tue Oct 30, 2018 7:25 pm

First of all, let me thank you for helping me.

What i'm not able to do? Well, i have images: A, B, C, D, ecc.

With Xviewer i launch all of them together and they are displayed on screen... Now i have to move the images in a way that all of them, are displayed (not hidden).

To achieve this, i need to resize the images in a specific way, for example A will be 400x500, B under A with 500x500 (just an example eh, dunno if it will fit), but let's say that there's C that need a 100x100 dimension.

Since Xviewer have a min resize setting, i would like to bypass this and allow C to be a 100x100.

Hope this help.

User avatar
smurphos
Level 8
Level 8
Posts: 2246
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher...

Re: Muffin: change window min dimension

Post by smurphos » Wed Oct 31, 2018 1:37 am

The general command to set a dimension via the command line would be...

wmctrl -r "Image Viewer" -e 0,-1,-1,100,100

Unfortunately this doesn't override the minimum dimensions hardcoded into xviewer.

You'd need to recompile form source having edited - https://github.com/linuxmint/xviewer/bl ... r-window.c

Code: Select all

#define XVIEWER_WINDOW_MIN_WIDTH  440
#define XVIEWER_WINDOW_MIN_HEIGHT 350
Other ways around it is to try another image viewer.

Feh is a good one - ideal for tiling with no minimum window size - apt install feh. It doesn't have a menu entry but should be an option in the open with menu on right-click a image file. Or you can use it from the terminal.

For your use case in general I'd also suggest installing the third party extension gTile - that gives you way more options for tiling windows - although again can't override the minimum dimensions set by an application.

Open the Extension settings module - navigate to Download panel and pick gTile, click the download icon. Go back to the main panel and click the + button to activate. Super-G to bring up the gTile GUI.

More info - https://cinnamon-spices.linuxmint.com/e ... ns/view/21

tobian
Level 1
Level 1
Posts: 6
Joined: Wed Jun 27, 2018 1:19 pm

Re: Muffin: change window min dimension

Post by tobian » Thu Nov 01, 2018 5:53 am

Thank you very much bud, this solved my problem!

Feh wasn't an option at all, since gif support was needed, but the recompilation of IV was smooth!

gtile instead was very helpful! Thank you again, you're very kind and helpful!

Post Reply

Return to “Cinnamon”