I am lacking the ability to 'close all files but this'

Post any comments, suggestions, annoyances or ideas for future releases here. Please do not post bug reports or questions here.
Post Reply
Arthur
Posts: 22
Joined: Fri Jan 13, 2012 3:50 am

I am lacking the ability to 'close all files but this'

Post by Arthur » Sun Jan 15, 2012 4:19 am

I am lacking the option of being able to close all files, except the current one in one click.
I just find it very convenient to be able to leave the currently active file open instead of closing each irrelevant one up individually.

jussij
Site Admin
Posts: 2512
Joined: Fri Aug 13, 2004 5:10 pm

Post by jussij » Sun Jan 15, 2012 6:54 am

I am lacking the option of being able to close all files, except the current one in one click.

The following macro will implement this behaviour:

Code: Select all

--
--        Name: Close Windows
--
--      Author: Omer Kircher
--
--    Language: Lua Macro
--
-- Description: This macro function will close all but the current window.
--

function key_macro()

  local count = get_window_count()

  local current_id = get_window_id()

  for index = 0, count, 1 do
    if current_id == get_window_id() then
        WindowPrevious()
    else
        -- close the window
        if FileClose() ~= 1 then
            -- user hit cancle on the close
            break
        end
    end
  end
end

key_macro() -- run the macro

Arthur
Posts: 22
Joined: Fri Jan 13, 2012 3:50 am

Post by Arthur » Sun Jan 15, 2012 9:15 pm

Awesome, a very programmatic way!
However, I can see there is a Document List implemented (Alt-B, hmm perhaps should be Alt-D, nevertheless), that one is probably the one that should get my missing functionality, just one more button (there is space!) added as say "Close All But Highlighted" would be a terrific + in its usability.

jussij
Site Admin
Posts: 2512
Joined: Fri Aug 13, 2004 5:10 pm

Post by jussij » Mon Jan 16, 2012 1:20 am

However, I can see there is a Document List implemented (Alt-B, hmm perhaps should be Alt-D, nevertheless)
Luckily this is very easy to fix ;)

Use the Options, Editor Options menu, select the Keyboard Mapping panel and hit the Edit button.

In the resulting dialog type in Alt+B and delete the binding. Then hit the Alt+D , remove any binding it may currently have and then assign the key to the FileListDisplayEx function.

NOTE: This is the same dialog that allows you to bind a keyboard key to a macro. Just change the Category option.
that one is probably the one that should get my missing functionality
I will look to add this functionality to this dialog.

Cheers Jussi

jussij
Site Admin
Posts: 2512
Joined: Fri Aug 13, 2004 5:10 pm

Post by jussij » Fri Jan 27, 2012 1:39 am

This functionality is now in the latest version of Zeus.

For more details see here: http://www.zeusedit.com/zforum/viewforum.php?f=6

Cheers Jussi

Post Reply
kuchnie warszawa opinie

Who is online

Users browsing this forum: No registered users and 0 guests