Change default window size when opened

Please post suggestions for improvement of Cinnamon here
https://github.com/linuxmint/Cinnamon
Post Reply
jharris1993
Level 3
Level 3
Posts: 115
Joined: Mon Nov 05, 2012 9:43 pm
Location: Woprcester Ma. (USA) when I'm not in Moscow Russia
Contact:

Change default window size when opened

Post by jharris1993 » Fri Nov 30, 2012 12:38 am

First of all:
I discovered Mint/Cinnamon, when Linux Format crowned it King of the Distributions. Since I was becoming increasingly unhappy with where Ubuntu was heading, (The Twilight Zone?), I wanted a change. Mint 13 and now Mint 14 has now become my Linux of Choice - and I have discovered that many of my Linux pals, and even a few strangers, are making the switch.

Thanks for an excellent distribution!

Second:
Please accept my apologies if this question has already been asked. After about fifteen minutes searching the Web and the various Mint fora, I have not yet found an answer.

Issue:

When I open any window, for any application, within Mint 13 or 14, the window always opens in "full screen" mode, completely covering whatever was there on the screen.

If I take a window out of full screen mode, close it, and then re-open it, it again returns to full-screen mode.

I opened gconf-editor, went to desktop ==> cinnamon ==> windows since several articles said that window specific settings were found here. In my case there was only one entry: Theme - MintX

How do I:
1. Get the windows to open at a reasonable size, instead of full-screen mode.

2. Get the windows to remember last-placed position and dimensions when closed.

Thanks again for a wonderful distribution.

Jim (JR)
Jim "JR"

Some see things as they are, and ask "Why?"
I dream things that never were, and ask "Why Not".

Robert F. Kennedy

“Impossible” is only found in the dictionary of a fool.
Old Chinese Proverb

remoulder
Level 17
Level 17
Posts: 7638
Joined: Fri May 09, 2008 1:14 pm
Contact:

Re: Change default window size when opened

Post by remoulder » Fri Nov 30, 2012 5:19 pm

jharris1993 wrote:window always opens in "full screen" mode
Do you have maximus (check in synaptic) or the maximus applet (check in Cinnamon settings) installed? If so remove/disable it.
[Edit] your original post and add [SOLVED] once your question is resolved.

“The people are my God” stressing the factor determining man’s destiny lies within man not in anything outside man, and thereby defining man as the dominator and remoulder of the world.

HealingTek
Level 1
Level 1
Posts: 2
Joined: Wed Jan 25, 2012 9:38 am

Re: Change default window size when opened

Post by HealingTek » Wed Dec 19, 2012 5:44 am

I have this same problem since installing Mint 14. No maximus package or applet is installed. It's driving me a bit nuts. Any suggestions on how to get it to stop doing this?

Ideally I'd really like windows to open with the same geometry as they were at when last closed, but I'd settle for at least not being maximized.

te7
Level 1
Level 1
Posts: 42
Joined: Thu Jan 12, 2012 10:28 pm

Re: Change default window size when opened

Post by te7 » Wed Dec 19, 2012 6:57 am

I also find this annoying. A solution would be nice.

herbie643
Level 3
Level 3
Posts: 160
Joined: Tue Oct 19, 2010 9:16 pm

Re: Change default window size when opened

Post by herbie643 » Fri Dec 21, 2012 10:00 pm

My sentiments exactly. Firefox, sending a link from Firefox cause maximized windows.
Hope a solution is forthcoming.

frisket
Level 1
Level 1
Posts: 20
Joined: Thu Dec 07, 2017 7:26 pm

Re: Change default window size when opened

Post by frisket » Mon Mar 11, 2019 6:19 pm

Nope. I just installed Mint 19 and the problem is still there. Almost all applications open maximised by default and there seems to be no way to stop it.

Who would be the person responsible for this: obviously not an application developer, someone working on the OS.

jharris1993
Level 3
Level 3
Posts: 115
Joined: Mon Nov 05, 2012 9:43 pm
Location: Woprcester Ma. (USA) when I'm not in Moscow Russia
Contact:

Re: Change default window size when opened

Post by jharris1993 » Tue Mar 12, 2019 8:15 am

remoulder wrote:
Fri Nov 30, 2012 5:19 pm
Do you have maximus (check in synaptic) or the maximus applet (check in Cinnamon settings) installed? If so remove/disable it.
Nope. At least not explicitly. Is it installed by default? ("Default" of the distribution package maintainer? :wink: )

My installs are always pure stock installs with the following exceptions:
  • I set the logon type to "automatic login".
  • I install a few, (IMHO), essential system utilities like gddrescue, gparted, Grub customizer, and Kuser.
  • I change the time display in the taskbar from 24 hour time to 12 hour time and the date format from the European date order to the US date order.
  • Depending on what I am doing with a particular install, I may also install Clam / the Clam desktop interface and/or the printer driver for my HP Officejet Pro 6970 Multifunction Printer.
Except for these changes, the installations are stock desktop installs. No LAMP stack, no roving eyeballs, no Energizer Bunnies, etc.

As I recall, the behavior of windows is the same before and after these changes are made.
Jim "JR"

Some see things as they are, and ask "Why?"
I dream things that never were, and ask "Why Not".

Robert F. Kennedy

“Impossible” is only found in the dictionary of a fool.
Old Chinese Proverb

User avatar
smurphos
Level 12
Level 12
Posts: 4320
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher
Contact:

Re: Change default window size when opened

Post by smurphos » Wed Mar 13, 2019 2:25 am

Unless a window size geometry is explicitly set by the application the default behaviour for Cinnamon/Muffin is to open in the same state as when the window was last closed. So Close a browser maximised it will re-open maximised. Close it windowed it will reopen windowed.
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.

jharris1993
Level 3
Level 3
Posts: 115
Joined: Mon Nov 05, 2012 9:43 pm
Location: Woprcester Ma. (USA) when I'm not in Moscow Russia
Contact:

Re: Change default window size when opened

Post by jharris1993 » Wed Mar 13, 2019 5:41 am

smurphos wrote:
Wed Mar 13, 2019 2:25 am
Unless a window size geometry is explicitly set by the application the default behaviour for Cinnamon/Muffin is to open in the same state as when the window was last closed. So Close a browser maximised it will re-open maximised. Close it windowed it will reopen windowed.
Smurphos,
In my original posting, I said:
When I open any window, for any application, within Mint 13 or 14, the window always opens in "full screen" mode, completely covering whatever was there on the screen.

If I take a window out of full screen mode, close it, and then re-open it, it again returns to full-screen mode.
Though I don't remember testing this any time recently, others have confirmed that this behavior still exists in versions up to the current 19.1 version.

So, what happens is that if a window is closed in a size less than maximized - (i.e. The windows has been resized.) - when you re-open the window, it re-opens fully maximized again.
Jim "JR"

Some see things as they are, and ask "Why?"
I dream things that never were, and ask "Why Not".

Robert F. Kennedy

“Impossible” is only found in the dictionary of a fool.
Old Chinese Proverb

User avatar
smurphos
Level 12
Level 12
Posts: 4320
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher
Contact:

Re: Change default window size when opened

Post by smurphos » Wed Mar 13, 2019 3:25 pm

jharris1993 wrote:
Wed Mar 13, 2019 5:41 am
So, what happens is that if a window is closed in a size less than maximized - (i.e. The windows has been resized.) - when you re-open the window, it re-opens fully maximized again.
I can't reproduce that behaviour, and have never come across it as an issue myself (Cinnamon 18 through to 19,1). It works for me as I describe. Is this any particular application(s) or in general?

I suspect that people suffering this issue have root owned files in their home as most apps store last state geometry in local config files.

Code: Select all

sudo chown -Rc $USER:$USER $HOME
will fix that.
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.

jharris1993
Level 3
Level 3
Posts: 115
Joined: Mon Nov 05, 2012 9:43 pm
Location: Woprcester Ma. (USA) when I'm not in Moscow Russia
Contact:

Re: Change default window size when opened

Post by jharris1993 » Thu Mar 14, 2019 2:58 am

Assuming a stock install, how would that happen?
Jim "JR"

Some see things as they are, and ask "Why?"
I dream things that never were, and ask "Why Not".

Robert F. Kennedy

“Impossible” is only found in the dictionary of a fool.
Old Chinese Proverb

User avatar
catweazel
Level 19
Level 19
Posts: 9493
Joined: Fri Oct 12, 2012 9:44 pm
Location: Australian Antarctic Territory

Re: Change default window size when opened

Post by catweazel » Thu Mar 14, 2019 3:16 am

jharris1993 wrote:
Thu Mar 14, 2019 2:58 am
Assuming a stock install, how would that happen?
More than likely by executing GUI applications as root that shouldn't be run as root.
¡uʍop ǝpısdn sı buıɥʇʎɹǝʌǝ os ɐıןɐɹʇsnɐ ɯoɹɟ ɯ,ı

jharris1993
Level 3
Level 3
Posts: 115
Joined: Mon Nov 05, 2012 9:43 pm
Location: Woprcester Ma. (USA) when I'm not in Moscow Russia
Contact:

Re: Change default window size when opened

Post by jharris1993 » Thu Mar 14, 2019 7:59 am

Yep.

Silly me, I gotta stop running those GUI apps.

You know, useless stuff like Gparted, kuser, Synaptic, update manager and - God help me - that damned root terminal. It'll get you every time! :shock: :wink:
Jim "JR"

Some see things as they are, and ask "Why?"
I dream things that never were, and ask "Why Not".

Robert F. Kennedy

“Impossible” is only found in the dictionary of a fool.
Old Chinese Proverb

User avatar
smurphos
Level 12
Level 12
Posts: 4320
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher
Contact:

Re: Change default window size when opened

Post by smurphos » Thu Mar 14, 2019 8:39 am

The problem is when you use a plain sudo to run a GUI app from the terminal. Using polkit or the now deprecated gksudo was OK. A plain sudo runs the app as root but with the user's $HOME which is where things can start going a bit strange.
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.

jharris1993
Level 3
Level 3
Posts: 115
Joined: Mon Nov 05, 2012 9:43 pm
Location: Woprcester Ma. (USA) when I'm not in Moscow Russia
Contact:

Re: Change default window size when opened

Post by jharris1993 » Thu Mar 14, 2019 2:00 pm

Smurphos,

Let me clarify this for everyone out there in our Television Audience. . . :wink:

I have two terminal window launchers set up. One is a normal, plain-vanilla terminal the way they normally work. The other is the exact same thing except that instead of something like "terminalcommand" I substitute "gksu terminalcommand" - which gives me a terminal that starts as a root terminal - after I enter my credentials.

In the same way, I have two file-manager launchers. One is the plain vanilla file-manager - "file-manager %U" and a special "root" file manager "gksu file-manager /" that runs a privileged file manager instance, beginning in the root of the file system.

I do this because 99.9999999. . . .99999999. . . .99999% of the work I do in Linux is some kind of administrative task or file-system recovery task that always requires elevated privilege so that I can poke around in a damaged file system, modify system configuration files, delete "untouchable" hidden stuff like Windows virii - or run things like hdparm to modify and/or securely erase hard drives. (etc.)

Will running applications like these via gksu cause the problem we're discussing?
You mention that "gksu" is being depreciated - what is the replacement?

Thanks!
Jim "JR"

Some see things as they are, and ask "Why?"
I dream things that never were, and ask "Why Not".

Robert F. Kennedy

“Impossible” is only found in the dictionary of a fool.
Old Chinese Proverb

User avatar
smurphos
Level 12
Level 12
Posts: 4320
Joined: Fri Sep 05, 2014 12:18 am
Location: Britisher
Contact:

Re: Change default window size when opened

Post by smurphos » Thu Mar 14, 2019 2:50 pm

So gksu is a su/sudo wrapper - as-well as presenting a gtk dialog for authentication it also ran su / sudo with parameters to ensure that the target users $HOME was used and that the calling users ~/.Xauthority file ownership isn't inadvertently changed. In short it was a trouble free way to run GUI apps as root.

Unfortunately it was abandoned by it's developer in 2014 and soon after a security issue was disclosed that was never been patched. It wasn't major but never the less it was removed from the Debian repos and from Ubuntu 18.04 / Mint 19 onwards is no longer available.

Instead applications that have a genuine need to escalate privileges should ship a polkit rule so they can be run with pkexec, Alternatively files can be accessed with privileges using admin:// (e.g xed admin:///path/to/some/file) - this method still using polkit to authenticate.

More on polkit - https://wiki.archlinux.org/index.php/Polkit
For custom Nemo actions, useful scripts for the Cinnamon desktop, and Cinnamox themes visit my Github pages.

Post Reply

Return to “Cinnamon”