PDA

View Full Version : [gnome] Gedit opens files in new window instead of new tab



ayoli
April 25th, 2008, 01:58 PM
Hi,
In hardy, gedit keeps opening files in new window instead of in a new tab when there is already an instance running.
Is this a bug or a feature ?
I've searched every where an option about that (even in gconf) but didn't find anything or missed it).
Any clue ?

Tim Sharitt
April 25th, 2008, 06:00 PM
The only time files open in a new window instead of a new tab for me is if I open a file from a different desktop than the one gedit is running on.

ayoli
April 25th, 2008, 09:26 PM
Here it happens even if I open a file from the same desktop.
It is very annoying :(

obscenic
August 30th, 2008, 03:09 AM
I'm having the exact same issue. This started happening as best I can tell, after the upgrade to heron.

KayWren
November 8th, 2008, 12:31 PM
I have the same problem! I had no problem with my former laptop (using hardy), the problem appeared with my new one (using hardy too).

Did ayoli or obscenic resolve finally this problem?

ayoli
November 8th, 2008, 01:03 PM
I have the same problem! I had no problem with my former laptop (using hardy), the problem appeared with my new one (using hardy too).

Did ayoli or obscenic resolve finally this problem?

I've just tried on my new 8.10.
Opening a file from the same virtual desktop where gedit is, the file opens in the same gedit window. If you try to open a file from another virtual desktop, it opens in a new window.
Not sure but I'm guessing that is possibly more a compiz issue than a gedit issue.

Bonne journée :)

KayWren
November 10th, 2008, 01:34 PM
I guess I should therefore upgrade my system. Thanks!

Et bonne journée !

KayWren
November 11th, 2008, 12:12 AM
I've just upgraded my system... and gedit continues to open files in new windows instead of new tabs. Damned!

KayWren
November 12th, 2008, 03:36 PM
Not sure but I'm guessing that is possibly more a compiz issue than a gedit issue.

Without compiz I still have this problem. I took a look in gconf-editor, but there is nothing about our tab problem in gedit configuration.

ayoli
November 12th, 2008, 11:18 PM
Without compiz I still have this problem. I took a look in gconf-editor, but there is nothing about our tab problem in gedit configuration.

Feel free to post a bug on gnome bugzilla (or comment an existing bug). I'll do the same when I'll have some time.
If you do so, please post the bug link here :)

b0b138
November 13th, 2008, 12:02 AM
right click said file > open with > open with other application. At the bottom expand use custom command. Then scroll though the list and click on Text Editor. Back at the bottom it should say gedit. If it happens to say gedit --new-window, delete the --new-window part

ayoli
November 13th, 2008, 12:10 AM
right click said file > open with > open with other application. At the bottom expand use custom command. Then scroll though the list and click on Text Editor. Back at the bottom it should say gedit. If it happens to say gedit --new-window, delete the --new-window part

not a bad idea but :
let say I have gedit opened on desktop 1, now I go to desktop 2 for some reason and try to open a text file from this 2nd desktop : gedit will open a new window.
Now if I stay on the desktop 1 and try to open a text file from the desktop 1 gedit opens the file in a new tab.

b0b138
November 13th, 2008, 12:33 AM
Did it say --new-window?

Mine does the same thing. Seems to make sense though. If I'm on desktop 2, I'm not sure I would want an opened file to go to another desktop

ayoli
November 13th, 2008, 01:04 AM
Did it say --new-window?

Mine does the same thing. Seems to make sense though. If I'm on desktop 2, I'm not sure I would want an opened file to go to another desktop

nope, it doesn't say --new-window

And I've choosen to have gedit on desktop one for some reasons but may have to open a file in gedit from another desktop, that was working before hardy.

KayWren
November 15th, 2008, 01:59 PM
right click said file > open with > open with other application. At the bottom expand use custom command. Then scroll though the list and click on Text Editor. Back at the bottom it should say gedit. If it happens to say gedit --new-window, delete the --new-window part

I tried that but it just says 'gedit', there is no '--new-window'.



Feel free to post a bug on gnome bugzilla (or comment an existing bug). I'll do the same when I'll have some time.
If you do so, please post the bug link here

Thanks ayoli!

I've just took a look in gnome bugzilla, and I've found something interesting (http://bugzilla.gnome.org/show_bug.cgi?id=559280) (your former idea about compiz seems to be the good one).

But I don't know where is 'gedit-app.c'...

ayoli
November 15th, 2008, 02:23 PM
I tried that but it just says 'gedit', there is no '--new-window'.




Thanks ayoli!

I've just took a look in gnome bugzilla, and I've found something interesting (http://bugzilla.gnome.org/show_bug.cgi?id=559280) (your former idea about compiz seems to be the good one).

But I don't know where is 'gedit-app.c'...

A .c file is a source code file, means you'll find this in gedit source code. you can get it from the repositories using

apt-get source gedit
Before doing that, check that you have the deb-src (sources repos) enabled in System > Admin > Software sources

KayWren
November 15th, 2008, 03:03 PM
I'll try that!

I guess I should uninstall gedit first, shouldn't I? And when I'll modify source files, I should compile gedit?

(Me, a noob? :mrgreen: )

grossvogel
February 14th, 2009, 09:49 PM
I was having this problem, too. The bug report noted above and the proposed patch indicate the the problem is with the size of the currently-open gedit window, so here's an idea:

Just un-maximize your existing gedit window to be just a little bit shorter than your screen. If you're lucky like me, subsequent invocations of gedit will open the doc in the same window!

Not as easy as if the app worked exactly the way I want, but quicker than mucking around in the source code.

nortexoid
November 2nd, 2009, 12:25 PM
I have the same problem as well and it has to do with whatever handles virtual workspaces (or with how gedit handles interacting with them). Opening in new tabs within the same window is fine if you're opening the files from the same workspace as gedit. Otherwise it opens a new window.

This might be desired behavior, but it isn't for me and apparently others as well. It would be nice if there were some option to change this (even it requires mucking around with config. files). Is there?

ZankFrappa
February 8th, 2011, 04:13 PM
I just stumbled upon that bug (/ feature or whatever). The bug filed in bugzilla says "fixed" though.

It doesn't help to unmaximize the window, when I execute 'gedit --new-document' from another workspace I get a new toplevel window - no matter what I do with the existing gedit...

Should I file a new bug?

arkmundi
September 2nd, 2011, 06:04 PM
New Dell Inspiron 15R, fresh install of Ubuntu 11.04, same problem and I have not yet found a cure. As with others, I prefer one gedit session and all files displayed in tabs, rather than what is apparently the default for Unity: openning files in a new window. Its possible to open files using the open button, which then opens the files in new tabs. But if using Nautilus to navigate and open - new window. Maybe its Nautilus thing? Help would be appreciated.

ThomWilhelm
October 23rd, 2011, 12:08 PM
Sorry to bring up a really old thread but I'm having this exact same issue but in 11.10, I was having the same problems in 11.04.

Basically if I already have a text file open then double click another file in Nautilus, it creates another gedit session rather than just opening it in a new tab in the current session.

As I find Unity very awkward to switch windows it makes this bug even more annoying. If anyone has any ideas then let me know. I'm going to file it as a bug to see if I can get some help with it.

Cheers.