Remove border from a notebook - gtk

I have a GtkNotebook and inside a GtkScrollView with a GtkImage. The Notebook is at the bottom-right side of the window (above is the toolbar, to the left is an options pane), and I would like to remove the border to the bottom/right from the Notebook (i.e. from each page), marked red in the screenshot below.
The following didn't have any effect (for the right side only), using the Ambiance theme.
notebook->get_style_context()->set_junction_sides(JUNCTION_RIGHT);
notebook->get_style_context()->get_border().set_right(0);
notebook->set_show_border(false);

I haven not managed to do this myself, but this might help:
https://bugzilla.gnome.org/show_bug.cgi?id=123408

Related

VSCode suddenly opening panel at the bottom of the screen (ignoring settings)

I don't understand the change of the panel not being where it's supposed to be.
Suddenly, pressing command+J opens the panel at the bottom of the screen, instead of to the right. I have not changed anything in my settings, although this error message seems to have turned up in my settings since the last update;
Workbench › Panel: Default Location
With the introduction of the side panel, the panel position is no
longer able to be moved in favor of moving view containers between
the panels.
Googling this does not give me any results. What does it mean?! What side panel, if not THE side panel (which is now a bottom panel) are they talking about?
See https://github.com/microsoft/vscode/issues/141349#issuecomment-1033046397 for an update on the changes made in v1.64 on this issue and inclusion in the recovery build soon.
The recovery build is out:
In v1.64.2 which hasbeen released. Put the Side Bar on the right and use the command View: Move Panel Right (or Left or Bottom). In one workspace with the setting Workbench > Panel: Default Location : right it put the Panel to the right of the Side Bar (so far right) but triggering the command fixed that. Editor | Terminal (Panel) | Side Bar. And working if put on the left too.
With the Recovey Build mentioned above, the following answer is largely "deprecated". I'll leave it for historical purposes.
This behaviour, of moving the Panel to the bottom despite your panelLocation setting is the result of the new Side Panel coming to Stable v1.64. The olde workbench.panel.defaultLocation setting has been deprecated and the Panel will remain at the bottom despite the defaultLocation setting. [Apparently, "deprecated" in this case means ignored.]
But, now you can have the traditional Side Bar on one side, the new Side Panel on the opposite side and the Panel on the bottom. Or turn off any of those.
Replacing Panel Location
As mentioned above, the new Side Panel provides similar functionality
as moving the Panel to the left or right, yet improves on this by not
forcing the move of the original panel. Along with view drag and drop
between panels, the new Side Panel is replacing the option to move the
bottom Panel.
In light of that, we have deprecated the
workbench.panel.defaultLocation setting as well as the Move Panel...
commands in favor of similar commands Move Views From Panel To Side
Panel (workbench.action.movePanelToSidePanel) and Move Views From
Side Panel To Panel (workbench.action.moveSidePanelToPanel). The old
commands will remap to the appropriate new command providing the
similiar behavior. Though, we recommend updating your keybindings to
the new commands.
See more here: Release Notes: New Side Panel

In VS Code can I change the width of the split editor panel with a shortcut or command?

In VS Code When I have a vertical editor split with 2 panels I would like to be able to change the right panel's width to a predefined total window width % using a shortcut.
Say I would like to have one shortcut to show the right panel at 50% of the overall VSC width. Then the second shortcut is 30%, the third is 80% and the 4th is 0%.
At the same time I would not like to have any files from the right editor panel joined or closed when I change the panel's width.
Is it posssible with the built-in commands of extensions?
I discovered the VS Code behavior that partially resembles the feature I described above.
To see this we have to split the editor in 2 panels (View->Editor Layout->Two Columns), open some file in the right hand one, manually move its border to the farthest right. Then as we switch between the panels with Ctrl-1 and Ctrl-2 (Windows) the respective active panel will restore its maximum width and the other will get the minimum width.
This does not fully solve my problem but at least alleviates the pain.

How to detach Outline from Explorer

Problem: Detaching the Outline section from Explorer and moving it to the right side.
Tried: right-clicking, changing the settings - cannot find where and how the Outline section be detached from Explorer.
Question: is it possible to detach the Outline Panel from Explorer Panel?
Is there another extension, which the same functionality as Outline, which could be placed on the right side?
Thank you!
This should be supported directly in VSCode 1.64 (Jan. 2022), with the new side panel.
New Side Panel
This milestone, we introduce the Side Panel, a new surface in the workbench to house views from the Side Bar or the bottom Panel appearing opposite the Side Bar.
Unlike the historical ability to move the bottom Panel to the left or the right of the editor, the new Side Panel works in addition to the bottom Panel so you can see more sets of views at once.
To use the Side Panel, you'll need to move some views over to it.
Based on one of our most upvoted feature requests, you might want to move Outline from the Side Bar to Side Panel.
You can do this by dragging and dropping the view into the Side Panel.
If the Side Panel is not open, just like the bottom Panel, dragging a view to the edge of the editor area, will pop it open.
Alternatively, you can use the Move View command for something more keyboard friendly.
Moving Outline View to the Side Panel:
Yes you can, click on the Outline Title Bar and you can move it to any other panel, even the bottom Problems/Terminal panel.
You don't need any special extension for it. Almost all panels can be moved around in VSCode
You cannot have a Floating Window however.
You also Cannot have Two Sidebars
If you want to have the sidebar to the right go to View - Appearance - Move Side Bar Right
As of now, no you cannot have two sidebars, this is the issue tracking that feature.
I can suggest an alternative, you can move the outline to the bottom panel, where the terminal is so that you can have both at the same time but just not as a sidebar.
like this:
or like this but attaching two Bottom Panel tabs together.
Here is a Demo on how to do it
So after a lot of searching, I finally came up with my own solution. Apologies in advance for the poor screenshot quality. I used Microsoft's Steps Recording not realizing the image compression would be so poor.
First, open up a new terminal (Ctrl+Shift+`)
Make sure that the terminal tab is active in the panel. Right click the terminal name on the right-hand side and select "Move into editor area.
"
You can then right-click the now-tabbed Terminal in your editor space and select "Split down."
Your editor should look like the image below. However, we're not done yet! Here's where the magic happens. Open another terminal.
Things will look weird but this is going to work.
Click the "Outline" header in the sidebar and drag it into the bottom terminal panel:
Sidebar > (Outline) > Terminal Panel
Next, right-click on the tab bar of the bottom panel and select "Move Panel Right"
Et voila! You should how have a sidebar on the left, and Outline on the right, and a Terminal on the bottom!

How to move Output or Terminal back into the panel in the window layout?

Recently in VS Code, somewhere around v1.42 or v1.43, we gained the ability to move around the following windows/panels that used to be stuck in the panel:
Terminal
Output
Debug Console
Problems
They could be split into multiple items in the panel itself (side-by-side or top/bottom, depending on whether the panel was at the bottom or left/right), and even dragged into the side-bar.
This was great, but after moving all of these windows to the side-bar while experimenting, I can't find any way to move them back into the panel. The panel is now empty, except for 3 dots (an ellipsis) in the upper left corner. You can still hide/show the panel, and move it left, bottom, or right, but there is nothing in it, and you can't drag anything to it. Dragging the terminal into the panel shows an icon that looks like it will successfully move (it's not the icon with the circle/cross-out you get other places it won't drop), but when releasing the click-drag, nothing happens.
I had just upgraded to v1.45.0 when this happened. It appears to be a defect, unless I'm missing something. Does anyone have a way to put the terminal or one of these other windows back in the panel, or reset their position? I combed the settings, and tried to find default setting's files (system or user) that might hold info on what is in the panel vs. the sidebar, etc., but couldn't find anything via search or on my PC. Any ideas?
Note: This is NOT about moving the panel between the left/right/bottom positions, or selecting the terminal/output/etc. in the panel itself. That's "old news", this is a recent feature.
Here is a view with the Terminal, Output, Debug Console, and Problems put at the top of the sidebar toolbar, and Terminal focused. The Panel is just to the right of the sidebar window, set to the "left" position, completely blank and useless. The "welcome" window on the far right side:
And here are my current settings:
See this issue https://github.com/microsoft/vscode/issues/96117 (Empty panel behaves weird)
Suggested fix:
Run the command View: Reset View Locations in the command palette.
Please see: https://www.technipages.com/visual-studio-reset-window-layout
Menu Window / Reset Window Layout worked for me in VS 2019

Can I have two side panels, one left and one right?

I have a nice wide screen, and in VS Code I would like some more room for both my file explorer and my code outline. So it would be nice if I could have two panels with in one the explorer and in the other the outline. Is this possible?
See https://stackoverflow.com/a/69329503/836330 This is in Stable v1.64.
Then View/Appearance/Show Side Panel or use the icon in the upper right as shown in the demo. That will open up a second side panel (on the opposite side of your Side Bar, the Side Bar is the panel which typically holds the Explorer view for example).
You can drag various views like the Outline view into this second "Side Panel".