Skip to content
This repository has been archived by the owner on Sep 6, 2021. It is now read-only.

[Linux] Brackets window position not remembered between launches #7174

Open
ingorichter opened this issue Mar 12, 2014 · 16 comments
Open

[Linux] Brackets window position not remembered between launches #7174

ingorichter opened this issue Mar 12, 2014 · 16 comments

Comments

@ingorichter
Copy link
Contributor

The window will always open at the same position. Moving the Brackets window to a different position, quit Brackets and reopen will show the window at the initial position.
I don't know how the initial position is determined, but it looks rather odd where the window gets placed (see screenshot with position after launching Brackets)

screenshot from 2014-03-11 19 51 19

@radorodopski
Copy link

Hi,

From what I could find, this is usually a job of the window manager in Linux, but some support from the application is also needed. This is all theoretical as the window managers say "this isn't our job" (and so does everybody else). I looked at the source of a few well-written linux apps and they all seem to have some code to:

  • remember the position and size of the window (on app exit), and
  • restore the size and the position of the window (on app startup)

I wrote a few lines of code just to experiment and it seems to work fine. I'm using a file to store the size/position in string format, and I read the file contents on application startup.
Using a file (in the application config directory) was the easiest method, with the least lines of code if I may say. If anyone has a better idea which isn't too hard to implement, I'd be interested to hear it (and it also has to be distribution-agnostic).

Let me know if you're interested in this and I will create a pull request.

@marcelgerber
Copy link
Contributor

@radorodopski Even though I'm not a collaborator, I think you should put up a PR as this is a highly requested feature.

@0zguner
Copy link

0zguner commented Feb 12, 2015

This bug still exists.

@radorodopski
Copy link

@marcelgerber , @mustafaozguner , I would but I don't know how quick the Brackets team would respond. I submitted adobe/brackets-shell#483 about 4 months ago and I still don't have any feedback from them. I don't know how busy they are or how much they care.

I don't have much time these days as I'm working on a project of my own but I think I may be able to find my local branch and create a PR, given that someone from the Brackets team still pays attention to the github issues page.

@nethip
Copy link
Contributor

nethip commented Mar 11, 2015

@radorodopski Sorry for not being able to look at the PR you had submitted. Because of the huge inflow of issues/PRs, it is taking more time for us to look at all of these.

On the Linux front, we are not there yet with integrating CEF 2171 succesfully. Off late we have been hitting a lot of "Crash On Quit scenarios". All of this work in going in this branch.

https://github.com/adobe/brackets-shell/tree/jasonsanjose/cef_2171_linux

It would be great if you can put up a PR for this. We would be more than happy to merge this to master on priority basis.

@1beb
Copy link

1beb commented May 13, 2015

+1 for posterity. Open maximized would be another useful option.

@zyberspace
Copy link

+1 (issue still exists)

@Corsseir
Copy link

2 years guys, 2 years and you still can't solve this issue.

@xfg
Copy link

xfg commented Apr 29, 2016

+1

@hazeray
Copy link

hazeray commented Mar 20, 2017

this is still a thing (ubuntu 16.04)

@abrahammurciano
Copy link

3 years and 2 months... that's 1200 days where no one has done anything about this 👎

@abrahammurciano
Copy link

I found that this command "wmctrl -r Brackets -b add,maximized_horz,maximized_vert" will maximise the window. I'm sure it can be adjusted to do anything else you need it to... If there was a way to automatically run this command when the program opens, that would make brackets maximise on open... Which is what I particularly want. If there is any way to do this, can someone let me know?

@abrahammurciano
Copy link

I made a script that will open Brackets maximised. It's not the best solution, but if (like me) you want brackets to open maximised, just use my script.
If not, you can customise the script to do whatever you want

Gist
AskUbuntu

@kenstuddy
Copy link

kenstuddy commented Oct 16, 2017

Still having this issue on Ubuntu 16.04 with Xfce4.12 DE.

Edit: To solve this on Ubuntu 16.04 with Xfce4 DE (the above solution did not work for me because I use Xfce4), follow this guide here: https://askubuntu.com/a/27833/475697 and then replace the code in file maximize.ds with this code: https://pastebin.com/VRpx9ghM

The benefit of the solution I found is that you don't need a script for launching Brackets, you simply start Brackets like normal and it will launch maximized. Since this issue does not happen on Windows and I am guessing does not happen on Mac although I have not tested it yet on Mac, I would call the fix I posted a good universal Linux workaround.

@joshmckibbin
Copy link

This issue still remains and is beyond frustrating.

@Corsseir
Copy link

Corsseir commented Mar 10, 2018 via email

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

16 participants