Open current selected directory on the other panel

You have encountered a problem using Far Manager? Here you can get help.
Post Reply
azatoth
Posts: 2
Joined: Wed 06 Mar, 2013 15:27

TotalCMD Target=Source feature in FAR

Post by azatoth »

Hi,

I like to ask you how can I replicate Total Commander's Target=Source feature in FAR?
What is does:
- if I press Ctrl+Right in the left panel it sets (or sends) the same path as in the left panel
- if I press Ctrl+Left in the right panel it sets (or sends) the same path as in the right panel

Or this feature is already exists in FAR?

Anyway I'm changing from TotalCMD to FAR and I like it!

Thanks in advance:
Aza
User avatar
HaRT
Moderator
Posts: 10823
Joined: Tue 30 Aug, 2005 17:21
Has thanked: 221 times
Been thanked: 358 times

Re: TotalCMD Target=Source feature in FAR

Post by HaRT »

Look for “Same folder” in the settings dialog of the FAR Commands standard plugin.
Although a more precise name would be “Same item” — you can adjust it in its LNG file.
Фар есть инструмент, а не нянька. © 2009 DrKnS
azatoth
Posts: 2
Joined: Wed 06 Mar, 2013 15:27

Re: TotalCMD Target=Source feature in FAR

Post by azatoth »

Oh yes, thanks!

This is what I wanted.

Now I love FAR even more!
crile
Posts: 2
Joined: Thu 28 Mar, 2013 15:22

Open current selected directory on the other panel

Post by crile »

Hi,

All is in the title, how to open the selected directory in the other panel ?

Thanks
2useven10
Posts: 5209
Joined: Mon 07 Sep, 2009 10:40
Has thanked: 18 times
Been thanked: 310 times

Open current selected directory on the other panel

Post by 2useven10 »

macros like this one (far3 only)

Code: Select all

Macro {
  area="Shell"; key="CtrlShiftBackSlash"; description="Current Folder --> Passive Panel";
  action = function()
    if APanel.Folder then
      local p = panel.GetPanelDirectory(nil, 1)
      local n = p.Name
      local t = #n > 0 and n:sub(-1) or ''
      local s = ''
      if #t > 0 and t ~= '/' and t ~= '\\' then
        s = n:sub(1,1) == '/' and '/' or '\\'
      end
      p.Name = p.Name .. s .. APanel.Current
      panel.SetPanelDirectory(nil, 0, p)
    end
  end;
} 
Last edited by 2useven10 on Sat 21 Dec, 2013 20:57, edited 2 times in total.
Игорь Юдинцев
Posts: 726
Joined: Sun 03 Apr, 2005 22:00
Location: Казань
Been thanked: 2 times

Re: Open current selected directory on the other panel

Post by Игорь Юдинцев »

crile
Posts: 2
Joined: Thu 28 Mar, 2013 15:22

Re: Open current selected directory on the other panel

Post by crile »

Thanks it works pretty well.
Where a can find a documentation for the macro language ?
2useven10
Posts: 5209
Joined: Mon 07 Sep, 2009 10:40
Has thanked: 18 times
Been thanked: 310 times

Re: Open current selected directory on the other panel

Post by 2useven10 »

crile wrote:Thanks it works pretty well.
Where a can find a documentation for the macro language ?
Some documentation you can find in %FARHOME%\Encyclopedia\... or here
But unfortunatelly somewhere it is not full and not up to date and mostly in russian.
User avatar
John Doe
Бюрократ
Posts: 13807
Joined: Wed 27 Apr, 2005 20:42
Has thanked: 73 times
Been thanked: 426 times
Contact:

Open current selected directory on the other panel

Post by John Doe »

2useven10 wrote:macros like this one
Macro can be even simpler:

Code: Select all

local ACTIVE,PASSIVE = 1,0
Macro {
  description="Current Folder --> Passive Panel";
  area="Shell"; key="CtrlAltShiftBackSlash"; flags="NoFiles";
  action=function()
    local dir = panel.GetPanelDirectory(nil,ACTIVE)
    panel.SetPanelDirectory(nil,PASSIVE,dir)
    dir.Name=APanel.Current
    panel.SetPanelDirectory(nil,PASSIVE,dir)
  end;
}
azatoth wrote:I like to ask you how can I replicate Total Commander's Target=Source feature in FAR?
What is does:
  • if I press Ctrl+Right in the left panel it sets (or sends) the same path as in the left panel
  • if I press Ctrl+Left in the right panel it sets (or sends) the same path as in the right panel
Here: http://forum.farmanager.com/viewtopic.p ... 28#p120028
pp
Posts: 36
Joined: Wed 24 Jan, 2007 11:39
Location: Česká republika
Has thanked: 8 times
Contact:

Re: Open current selected directory on the other panel

Post by pp »

And the way without macro: if left panel is active with dir C:\Windows\Temp and you want to open the same dir in the right panel - simply press "Alt+F2 C".
old_gregg
Posts: 46
Joined: Fri 01 May, 2015 16:04
Has thanked: 10 times
Been thanked: 1 time

Change passive panel to same directory as active panel?

Post by old_gregg »

Is there a hotkey to chdir the passive panel to the same directory as the active panel?
old_gregg
Posts: 46
Joined: Fri 01 May, 2015 16:04
Has thanked: 10 times
Been thanked: 1 time

Change passive panel to same directory as active panel?

Post by old_gregg »

Ah, I found it in the similar topics once I made the post: Alt+F2 C
peterf28
Posts: 2
Joined: Sun 04 Feb, 2024 11:06

Open current selected directory on the other panel

Post by peterf28 »

this plugin does not make the same action as does CTRL+left or CTRL+right in Total commander. This just sets it to the same directory, but not to the actual directory under the 'cursor'.

I would like to open the directory (same action as ENTER key), but to the other panel. Is it possible? THanks.
2useven10
Posts: 5209
Joined: Mon 07 Sep, 2009 10:40
Has thanked: 18 times
Been thanked: 310 times

Open current selected directory on the other panel

Post by 2useven10 »

You can use macros.
Like one that John Doe demonstated 5 posts ago.
Last edited by 2useven10 on Sun 04 Feb, 2024 13:18, edited 3 times in total.
peterf28
Posts: 2
Joined: Sun 04 Feb, 2024 11:06

Open current selected directory on the other panel

Post by peterf28 »

Ok, works, thanks.
Post Reply

Return to “Support and Troubleshooting”