Bug 66575 - Make Open as tab in existing Konq when URL is called externally independent from desktop
Summary: Make Open as tab in existing Konq when URL is called externally independent f...
Status: CONFIRMED
Alias: None
Product: konqueror
Classification: Applications
Component: tabbing (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR wishlist
Target Milestone: ---
Assignee: Konqueror Developers
URL:
Keywords:
: 99084 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-10-25 17:42 UTC by Mikolaj Machowski
Modified: 2009-11-22 11:03 UTC (History)
7 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Script to force opening in tab on existing konq, disregarding desktop (1.40 KB, application/text)
2005-02-12 21:09 UTC, Frisb Com
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Mikolaj Machowski 2003-10-25 17:42:58 UTC
Version:            (using KDE Devel)
Installed from:    Compiled sources
OS:          Linux

Option as in description doesn't work. It opens new Konqueror.
Comment 1 Stephan Binner 2003-10-25 18:55:01 UTC
Works here. How/where do you call the URL? What does "kfmclient openURL <URL>"? What the second time?
Comment 2 Mikolaj Machowski 2003-10-25 21:29:37 UTC
Subject: Re:  Open as tab in existing Konq when URL is called externally doesn't work

> Works here. How/where do you call the URL? 

kmail

>What does "kfmclient openURL<URL>"? 

Opens new konqueror with requested URL.

>What the second time?

Opens new tab in previously opened konq.


Comment 3 Stephan Binner 2003-10-27 20:10:48 UTC
Do you use Xinerama/Multihead? Or is your first Konqueror window on another virtual desktop or minimized? Does it make a difference if you turn off Konqueror preloading?
Comment 4 Mikolaj Machowski 2003-10-28 19:45:33 UTC
Subject: Re:  Open as tab in existing Konq when URL is called externally doesn't work

> Do you use Xinerama/Multihead? 

No

> Or is your first Konqueror window on
> another virtual desktop 

Yes. And here is cause. When Kmail and Konq are at the same virtual
desktop everything works OK.

> or minimized? 

No, but I will try it: when first Konq is minimized Kmail opens new Konq
(even if it is at the same virtual desktop as first Konq).
Ha. When I minimize the second Konq and try to Open URL once again Kmail
will open the next Konq - now I have three Konqis.

> Does it make a difference if you
> turn off Konqueror preloading?

No.

Hmm. After few thoughts, tests etc. I think that even if this is bug
(undesired, unplanned behaviour) some people could expect such
behaviour: when Konq window is on another virtual desktop or minimized
it is "closed". It is used for another activity and user doesn't expect
to use this instance for opening there pages connected with current
activity (eg. mail editing). But in this case he shouldn't check this
option (AFAIR this is not default setting). In worst case "just"
introduce sub-option: 
[ ] Open as tab in existing Konqueror when URL is called externally 
	[ ] Only when Konqueror is opened at current virtual desktop

Comment 5 Stephan Binner 2003-10-30 17:13:24 UTC
> some people could expect such behaviour: when Konq window is on another virtual desktop or minimized it is "closed".

That's how I thought about this when implementing it. :-) So this is planned behavior. One can argue about the minized state but I don't think that silently opening on another desktop or automatic switching it would be a good idea.
Comment 6 Mikolaj Machowski 2003-11-04 19:57:56 UTC
Subject: Re:  Make Open as tab in existing Konq when URL is called externally independent from desktop

>
> > some people could expect such behaviour: when Konq window is on another
> > virtual desktop or minimized it is "closed".
>
> That's how I thought about this when implementing it. :-) So this is
> planned behavior. One can argue about the minized state but I don't think
> that silently opening on another desktop or automatic switching it would
> be a good idea.

In this case with options shoul be description that it work only on
current virtual desktop (not minimized).

Comment 7 Tim Weber 2004-02-17 12:12:03 UTC
> In this case with options shoul be description that it work only on 
> current virtual desktop (not minimized).

This is implemented in the context help. Yet I think it wouldn't be too hard to implement a second option as described in #4. I personally like to have virtual desktops for certain tasks (one "console", one "IRC", one "mail" and one "web"), and if I click a link in KMail or anywhere else I really would like it to open in the Konqueror on the "web" desktop...
Comment 8 Mikolaj Machowski 2004-02-17 12:57:51 UTC
Agree. I have similar setup: MGT desktop, Web desktop, Kontact 
desktop. I don't want to open new Konq window. I understand why 
current behavior should be keep as default (less astonishing for 
new users) but introduction of this wish would be good thing for 
more advanced users. 

----------------------------------------------------
Narty i snowboard - niewiarygodnie zje
Comment 9 Ferdinand Gassauer 2004-05-11 09:23:40 UTC
IMHO the default should be to "display" the URL which is called externally, regardless how this happens (on same or different desktop, if konqueror is minimized or not)
IMHO only a minority of users click on a link aiming NOT TO SEE it.
Comment 10 Stephan Binner 2004-05-14 10:13:31 UTC
> IMHO the default should be to "display" the URL which is called externally

Which is happening with opening it right in front of your nose, I don't understand your comment Ferdinand. :-)
Comment 11 Mikolaj Machowski 2004-05-16 19:03:49 UTC
Yes, current behaviour isn't bad, but as Konqueror provides solution all in one, and some people prefer to have one Konq-shell for everything all other programs should redirect its requests to this one shell.
Comment 12 Stephan Binner 2005-02-11 11:13:19 UTC
*** Bug 99084 has been marked as a duplicate of this bug. ***
Comment 13 Frisb Com 2005-02-12 21:09:01 UTC
Created attachment 9580 [details]
Script to force opening in tab on existing konq, disregarding desktop

This might help others while waiting for the 'fix' described in this call.

The script moves the running konqueror onto the current desktop, loads the URL
into this instance, and moves konqueror back to its original desktop.  If konq.
is not already running, load one.

This script uses wmctrl to locate and move konqueror.  It also requires some
general tweaking to get to work-- debugging functions used here are not
included (just replace with echo).
Comment 14 Andrew Cooks 2005-05-11 14:36:58 UTC
*** This bug has been confirmed by popular vote. ***
Comment 15 Andrew Cooks 2005-05-12 09:20:57 UTC
After thinking about it, I have to say that I think the URL should be loaded in an existing konqueror, regardless of where it is, as the option says. One really cannot miss the flashing of konqueror in the task bar, indicating that it loaded the URL.

Does anyone actually like the current behaviour, or is it only done because it's less confusing for the default settings at first?
Comment 16 Mikolaj Machowski 2005-05-12 12:36:04 UTC
> After thinking about it, I have to say that I think the
> URL should be loaded in an existing konqueror, regardless of where it
> is, as the option says. One really cannot miss the flashing of konqueror
> in the task bar, indicating that it loaded the URL.


LOL :) <- that is heartly good laugh, not scoffing one :)
I WANT that option to work as is in bug description but after thinking 
about it (ehem ;) I think default behaviour is quite sane for beginners. 
It is nuisance for more advanced users who know how to use virtual 
desktops.

Besides, everything depends on individual work organization. I prefer 
Konsole on one desktop, Konqueror on second, even if I have several tasks 
all are grouped by app, not task. But other people could prefer different 
setup - group by task, not app. I think current setting is good for 
newbies and latter people. 
>
> Does anyone actually like the current behaviour, or is it only done
> because it's less confusing for the default settings at first?


It is less confusing for the default setting (IMO).
Comment 17 Tim Weber 2005-05-12 12:46:40 UTC
I agree that it might be less confusing for newbies. However, I'm no newbie anymore, and I would like the possibility to have exactly _one_ Konqueror eating up space in my task bar (showing all desktops' windows), not one per virtual desktop.
Comment 18 jamundso 2005-06-29 00:12:06 UTC
Interesting. For all the times I've checked the newTab syntax, I never even noticed the phrase "current active desktop" until now. It's unclear to me what direction this bug is going in, but my preference is to have it "newTab" - no more, no less - the assumption being I have konq running where and how I want it ... thus, just "newTab".

$ kfmclient --commands

Syntax:

[openURL snipped]

  kfmclient newTab 'url' ['mimetype']
            # Same as above but opens a new tab with 'url' in an existing Konqueror
            #   window on the current active desktop if possible.

Comment 19 Eduardo Habkost 2005-06-29 00:23:18 UTC
I have never noticed neither the WhatIsThis text for the new tab option on konqueror, neither the "current desktop" part of the help for newTab, too.

What I expect is:

 1. opening from external application: be able to tell konqueror that I don't care if the new tab will be opened on a different desktop. It would require an additional option to set that

 2. kfmclient newTab opening a new tab, no matter where, because I am being explicit about that. The first thing I've tried to workaround the feature of konqueror not opening a new tab on a different desktop is changing the command for opening an URL to 'kfmclient newTab', and I didn't expected it to open a new window when I was explicit to open a new tab

Currently, we have two calls: openURL and newTab. If implementing (2) above, I guess the current behaviour would need to be renamed to newTabIfCurrentDesktop, hence we would have three different possible calls (not necessarily with these names, of course): openURL, newTab and newTabIfCurrentDesktop.

I would be happy only with (1), but having (2) too would be nice.  :)
Comment 20 Atte Karkimo 2006-09-27 11:17:39 UTC
>Script to force opening in tab on existing konq, disregarding desktop

I had to change the line "declare -i konq_d=`wmctrl -l | grep -i $KONQ_BIN | cut -f2 -d' '`" to "declare -i konq_d=`wmctrl -l | grep -i $KONQ_BIN | cut -f3 -d' '`" for the script to parse wmctrl's output correctly, since there are two spaces before the desktop number.
Comment 21 Roberto 2006-10-10 12:09:41 UTC
I think that if beginners have problems with multiple desktop they should not use it. In fact, most distributions comes with a single desktop default configuration. If a user have multiple desktops, it means he knows how to manage them. 
Comment 22 Tarlika Elisabeth Schmitz 2006-11-14 12:28:25 UTC
Thank you for providing the script!

To get it to work, I had to make 2 changes:

1) KONQ_TITLE=Konqueror 
capital "K" as the konqueror window appears as "<page-title> - Konqueror"

2) pick the first konqueror instance from the grep result only:
declare -i konq_d=`wmctrl -l | grep -i $KONQ_TITLE | head -n 1 | cut -f3 -d' '`
The script as it is won't work if you have multiple konqueror instances running.

I also added an option -k to the script. If -k is passed, the konqueror instance will be kept on the desktop where it came from (script as above), if not it will be pulled to the current desktop. The latter imitates Galeon's behaviour (galeon -n <url>).
Comment 23 Roberto 2008-08-06 15:41:15 UTC
please close this bug!!
Comment 24 David Faure 2008-09-23 21:52:51 UTC
The request for a second checkbox makes sense I guess. It's just that there are so many checkboxes already ;-)
Comment 25 Rafael Leal 2009-11-22 11:03:17 UTC
Please, give us this option! The script didn't work for me.