New Opera Forums launching soon!
Discussion thread

Opera does not remember window size

aleskva
aleskva

1 posts

    Steps to reproduce: * On Arch Linux+Gnome install Opera from AUR repositories * After installation is done, start Opera * Maximize window * Close Opera * Open Opera

    Expected behavior: Opera will start in maximized window as it was closed

    Current behavior: Opera will start in smaller window and must be maximized again

    10 Replies - 483 Views

    jimunderscorep
    0 0
    jimunderscorep

    127 posts

      Same here (debian testing x64, openbox and opera installed from their repo). There is already an open topic about it, so please post there :)

      devlinp
      0 0
      devlinp

      3 posts

        I found this list http://peter.sh/experiments/chromium-command-line-switches/#start-maximized

        and it shows "-start-maximized" as a parameter.

        Put it in the Opera launcher and bingo. Opera now opens maximized with this command in the launcher:

        in Linux:

        opera %U --start-maximized

        jimunderscorep
        0 0
        jimunderscorep

        127 posts

          Thanks a lot for the tip!

          devlinp
          0 0
          devlinp

          3 posts

            Here's where this stands now:

            Opera now doesn't open properly in Linux Mint anymore, it doesn't open maximized by itself.

            If you open the launchers and change the command from "opera %U" to "opera %U --start-maximized", then it opens mid-size at first, then jumps to maximize. This is great!

            However, this only works in each specific launcher, and the "new window" and "new private window" options from the icon on the taskbar/panel, well, their launchers are "missing" - can't find them anywhere.

            Below is the file "opera.desktop" from "/usr/share/applications" in Linux Mint 18.1 Cinnamon.

            it's the only file I can find that refers to "new window" and "private window" - I couldn't find anything about opera in "~/.local/share/applications/" but there's other copies of this in

            /home/Username/.local/share/applications/userapp-opera-KE9M0Y.desktop /home/Username/.cinnamon/panel-launchers/cinnamon-custom-launcher-1.desktop

            But when I edit the 2 lines that say

            "Exec=opera --new-window" to say "Exec=opera --new-window, --start-maximized"
            and "Exec=opera --private" to say "Exec=opera --private, --start-maximized"

            there's no change in the window behaviour. What am I doing wrong here?

            This is the file, I edited it as root even:

            [code][Desktop Entry] Version=1.0 Name=Opera GenericName=Web browser Comment=Fast and secure web browser TryExec=opera Exec=opera %U --start -maximized Terminal=false Icon=opera Type=Application Categories=Network;WebBrowser; MimeType=text/html;text/xml;application/xhtml_xml;x-scheme-handler/http;x-scheme-handler/https;x-scheme-handler/ftp;application/x-opera-download; Actions=NewWindow;NewPrivateWindow;

            [Desktop Action NewWindow] Name=New Window Exec=opera --new-window TargetEnvironment=Unity

            [Desktop Action NewPrivateWindow] Name=New Private Window Exec=opera --private TargetEnvironment=Unity[/code]

            I'm really getting lost here - do we have someone who can see what I'm doing wrong? Does anybody know the right syntax for this? Specifically the "EXEC" lines.

            devlinp
            0 0
            devlinp

            3 posts

              How do I edit this so you can read the file contents? It's messed up.

              jimunderscorep
              0 0
              jimunderscorep

              127 posts

                You just change the 7th line in the file from

                Exec=opera %U
                

                to

                Exec=opera %U --start-maximized
                

                And here are the contents of the whole opera.desktop file if you want to check

                http://paste.debian.net/937473/

                (the link is valid for 7 days)

                dalatkid17
                0 0
                dalatkid17

                4 posts

                  new to both opera and also linux mint. I see your advice but not sure how to impliment. Can you do a step by step for a learner please

                  jimunderscorep
                  0 0
                  jimunderscorep

                  127 posts

                    Open the opera.desktop file like so

                    sudo gedit /usr/share/applications/opera.desktop

                    Find the line I mention above (the 7th one) and change it to what I say. Then save and exit.

                    dalatkid17
                    0 0
                    dalatkid17

                    4 posts

                      Put command in with this reply:sudo: gedit/usr/share/applications/opera.desktop: command not found

                      jimunderscorep
                      0 0
                      jimunderscorep

                      127 posts

                        There is a SPACE between "gedit" and "/usr/share/blablabla"... Please type it correctly :P