Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open documents into new tab rather than new window #148

Closed
mitya57 opened this issue Aug 19, 2015 · 6 comments

Comments

@mitya57
Copy link
Member

commented Aug 19, 2015

When I already have a ReText window open, I'd like to be able to double-click a file in the file explorer (Gnome Files) and have it open into a new tab on the existing window. Currently a new ReText window is opened instead. Thanks!

I'm using retext-5.0.2-2 on Fedora Linux 22.

Reported by: porjo38

Original Ticket: retext/tickets/148

@mitya57

This comment has been minimized.

Copy link
Member Author

commented Aug 20, 2015

This is non-trivial to fix and involves writing a lot of new code for inter-process communication. While I share your opinion (new tab is definitely better than new window), it may need to wait until I have a spare day for this.

Original comment by: mandriver

@mitya57

This comment has been minimized.

Copy link
Member Author

commented Aug 20, 2015

  • status: open --> accepted

Original comment by: mandriver

@Mte90

This comment has been minimized.

Copy link
Contributor

commented Oct 5, 2019

I developed a bit with PyQt and I can see that exist QtDbus also in python so I think that is possible to expose a signal.
In that way is possible to do a tiny script (or retext itself) that call dbus from retext and accept a file and will open a new tab.

@mitya57

This comment has been minimized.

Copy link
Member Author

commented Oct 5, 2019

A pull request adding that would be very welcome.

@Mte90

This comment has been minimized.

Copy link
Contributor

commented Oct 5, 2019

I am studying the code to see if I can do it.

I think that at https://github.com/retext-project/retext/blob/master/ReText/__main__.py#L92 I can see to emit the dbus signal when retext is started again.
Instead to the dbus listener I can use window.openFileWrapper(fileName) to open the file.
I can do it probably in the main file but I will let you know for updates in the next days.

@Mte90

This comment has been minimized.

Copy link
Contributor

commented Oct 6, 2019

I did it #476 :-D

I wrote a book with ReText (mentioned in tools used) and this is to say thank you to the project :-) #476

@mitya57 mitya57 closed this in ec3e50f Oct 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.