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

Add an ability to open editor in the specified column #3553

Closed
vinokurig opened this issue Nov 20, 2018 · 13 comments
Closed

Add an ability to open editor in the specified column #3553

vinokurig opened this issue Nov 20, 2018 · 13 comments
Assignees
Labels
todo larger scoped issues

Comments

@vinokurig
Copy link
Contributor

vinokurig commented Nov 20, 2018

Add an enum [Active, One, two, Three] to EditorOpenerOptions parameters and open the editor in the specified column when EditorManager.openEditor(params: EditorOpenerOptions) is called:
screenshot-localhost-3000-2018 11 21-10-32-38

is needed for #2801

@vinokurig vinokurig added the todo larger scoped issues label Nov 20, 2018
@akosyakov
Copy link
Member

akosyakov commented Nov 20, 2018

What do you mean by a separate area? Do you mean opening to the side? There are already options for it, please look at ApplicationShell.WidgetOptions.

@vinokurig
Copy link
Contributor Author

If you click on file in the navigator, it will be opened in a new tab:
screenshot-localhost-3000-2018 11 20-17-05-49
But I would like to have an ability to open the next editor in a separate tab:
screenshot-localhost-3000-2018 11 20-17-07-02

@akosyakov
Copy link
Member

Try widgetOptions: { mode: 'split-right' } or widgetOptions: { mode: 'split-bottom' } to open a new tab bar area to right or to bottom relative to last focused widget.

@vinokurig
Copy link
Contributor Author

Ok, thanks

@svenefftinge
Copy link
Contributor

can we close this?

@vinokurig
Copy link
Contributor Author

Let me try the proposed solution. I'll close it if it would work for me.

@vinokurig vinokurig changed the title Add an ability to open editor in separate area Add an ability to open editor in the specified column Nov 21, 2018
@vinokurig
Copy link
Contributor Author

@akosyakov Thank you for your advice but it didn't solves my issue. I've studied the vscode plugin system and found that current solution doesn't fit it. This can only open the editor in a new column, but I need to open the editor in the specified column as well.
P.S. Rephrased the issue

@akosyakov
Copy link
Member

akosyakov commented Nov 21, 2018

Our areas don't have the notion of columns. I think first you will need to simulate it somehow on the top of existing APIs in the plugin extension. Later if it is turned out to be useful for extension developers we can introduce such modes in the core.

@vinokurig
Copy link
Contributor Author

Our areas don't have the notion of columns

Column may be a wrong word but, anyway it is possible to open several editors in the same area (see the screen-shot in the description), so this issue is actual.

@svenefftinge
Copy link
Contributor

You can align the terminology with the one from the vs code API.

@vinokurig vinokurig self-assigned this Nov 23, 2018
@svenefftinge
Copy link
Contributor

svenefftinge commented Nov 23, 2018

Can you link to the respective part in vscode.d.ts?

@svenefftinge
Copy link
Contributor

svenefftinge commented Nov 23, 2018

Found it 'ViewColumn'.

I think that can be modelled within the plug-in extensions without modfiying the application shell too much.

@vinokurig
Copy link
Contributor Author

This is already implemented by widgetOptions: { ref: widget } in OpenerOptions. I'll open a PR for plugin side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
todo larger scoped issues
Projects
None yet
Development

No branches or pull requests

3 participants