How re-enable design palette in Android Studio - android-studio

I recently made the switch to Android Studio as my default IDE for Android development. When designing my UI I normally use the palette in the design view to assist in arranging the widget on the preview screen.Recently something weird happened, It just disappeared and I can't seem to re-enable it. Normally I would see the little Palette button on the side but now its gone. When I open another project I see the palette but not show this current project I'm working on.
When I open another project in Android Studio I see the palette tab.

I've just figured this out! If you double click on your .xml file tab at the top it will maximize the designer window. Then on the left you can drag the window to shrink and it will reveal the palette. Then just click on the tab on the left to open the project window.

try the Design/Text tabs in the lower left of the layout window

The palette can be shrunk to 0 width. This can be expanded by hovering next to the left edge of the design window, and finding the right-most expand position.

If you have only the designer and the properties showing and the Properties is on the right, you can get the palette back by switching to a left or right view.

Right click on the .xml file tab. Select "split vertically". This will open another Design that shows the palette again.

Android Studio 2.3.3, and the answer I was looking for:
Window -> Restore Default Layout (Shift+F12)

First Close All The Tabs Then Open res->layout->activity_main.xml
you will able to see design tab at activity_main.xml

Try to switch between Design/Text tabs at the bottom left of the editor.

You must have something in the layout resource highlighted. I also had to compile without an error.

My solution was traversing
src->main->res-layout->content_main.xml
then open content_main.xml

You have to be in the 'Design' tab (as opposed to the 'Text' tab) at the bottom of the middle window (the one that shows the phone).

Related

Why does Android Studio never show layout decorations when I open it?

As you can see in the image below, every time I open a project in Android Studio, the layout decorations option is deselected. How can I have it selected for default?
look on the top left of constraintLayout that you currently open, click on the eye icon and then click Show Layout Decorations. then you will be able to see it. but i don't know how to access it.
I think is not possible. I never see about that the solution

Android Studio Debug Watch pane is missing

OK this is really stupid. I have no idea what happened to the debug watch frame in Android Studio. I have 1.5.1 of Studio.
Is there some secret knowledge from intellij to show it.
Here's the icon that #jamesldurham referred to:
Thanks James! I think it would have taken me a long time to find that :/
Ok I with some help there is a button debug menu that looks like a desaturated American flag that when pressed brings it back.
The tool tip will show restore layout.
If you don't want to restore the entire debug layout, the below image is pointing to the "restore watches view" button. It is in the upper right corner of the debug console and looks like a pair of green shaded glasses over a window.
The button to its left restrores the "Threads" view, and to the right restores the "Variables" view.
Unlike previous IDEs the Watch panel is now totally integrated into the Variables panel
And there is no watch the variable option neither in the popup when right clicking on a variable.
The only option is to select the varaible that needs to be watched and drag and drop it onto the Variables panel.
Check that you have the Frames tab selected instead of Development, in the left bottom section.

Android Studio - view both Text and Design preview of layout

In Android Studio, how can I view both the text and design preview of an XML layout side by side.
I could see it by default when I installed Studio, but now that is gone,
and I'm not sure why. I can only see or the other.
How do I re-enable it?
Open your [whatever].xml. At the bottom you'll see Design and Text. Select Text. If you still can't see the actual layout, only xml, then select "Preview" which is located at the right of the window, between Gradle and Maven Projects.
Click on preview while text is selected.
At first, select your desired .xml layout from the Project tab then use Code, Split and Design buttons to switch between the views. (Android Studio 3.6)
Code - Display only XML part
Split- Display XML and design both
Design- Only design part
It appears that in Android 3.6.1, the buttons to select Design, Split, or Code have been placed in the upper right of the XML layout screen.
Select any one from the top right options to change the view of your Code and Design
You can split the tab by right-clicking on the tab and selecting either Split Horizontally or Split Vertically. Then, you can select the Design tab on one and the Text tab on the other.

How to restore VBA Editor to its initial settings?

How to restore the VBA Editor to its intial settings ? I have some troubles with macro and projects explorer windows settings, after some bad manipulations.
The only way I know how to accomplish this is to edit the registry.
Close All Office programs
Open a command prompt and type regedit
Navigate to HKEY_CURRENTUSER\Software\Microsoft\VBA\6.0\Common
Right click on Common and Export to save the *.reg file somewhere safe. This is your back up. Double clicking this file will restore your current settings.
Right click on Common and Delete it. Doing this will remove all of
its subkeys that hold your personal settings.
The "Common" key will be recreated the next time you close the VBA Editor along with any changes to the settings you may make.
I have the same issue, it's simple:
TOOLS
OPTIONS
DOCKING
Then select Object Browser, Project Explorer and that's all.
I had the same problem and realised that if I double click the blue heading of a minimal floating menu, such as the Project-VBAProject menu, it would resize and fit in with the other menus that are expanded. With a bit of moving around and double clicking the headers of the menus that I had selected from the VIEW option, I could get the screen back to the way it originally looked at the default setting of the VBA editor.
Phil
Solution Using a Mac and Excel 2016.
I found that I could drag the, e.g., project explorer (pe) window toward the edge of the vb window and the outline of the pe window moves and adjusts once you get close enough to the edge. This also works with the other windows as you bring them into view.
My default view is project explorer upper left, properties lower left. To return these to be in that order, drag the one to that location (which will fill that whole area) then drag the other one right on top of that one. That stacks them in the same column and then you can adjust their size within those locations.
I had this same issue and fought with it for literally 2 days. Finally figured it out!!!
xD First close the Project Explorer and the Properties windows using the X at the top right. Then go to Options under the Docking tab. Uncheck all boxes. Close the options window and if desired check to see that everything is undocked. Now go back to Options>Docking and check all the boxes you had checked (default is all but object browser). Your windows should have returned to default.
This may not solve the OPs original question of "default" for all, but in my case and possibly others I was looking to re-dock the "Project Explorer" and have modules pop up next to it like default. I'm not sure about other settings, but this is how I restored the above behavior.
In the project explorer right click and select "Dockable". Then insert a module and maximize it. This should restore what I consider default behavior.
Actually, it is very easy. You just have to go to View Tab then Click on the Project Explorer & Properties Window. It worked for me because I lost these two and now I got it by doing this. I hope so you will get the same result as well. View the image for more clarity.
Simple steps. Works for Mac , maybe windows too
Close all the tabs in the VBE
View --> Code . This will occupy entire space
After that ,view --> project explorer. this will pop up a tab, drag that tab to the top left corner. It auto fills into a small column which you can drag according to your preference .
Now select view --> properties window and drag the tab to bottom left.
Additional step ( if you use locals window )
Select locals window from view and drag it to the bottom.
Right click any of the window you want to move and click "Dockable". This should allow you to move all the windows as you want and place them as you wish.
I had all menus and windows missing, like no "File", no "Edit", no "View", etc.
Here's what I did:
Closed Excel
Opened the Registry Editor
Navigated to HKEY_CURRENTUSER\Software\Microsoft\VBA
Right clicked on VBA and renamed to VBA_old
Closed the Registry Editor
Opened Excel
Opened Visual Basic
…and voila, VBA was back to normal!
After that, I:
Reopened the Registry Editor and saw that VBA had been recreated
Deleted VBA_old
I'm not aware of a 'reset' command but the starting point would be to go to the View menu and start by setting the Code, Project Explorer and Properties windows and then the Toolbars>Standard (toolbar) perhaps?

Switching TabHost Tabs in Android Studio UI Designer

How can I switch between the tabs of a TabHost in the UI Designer for inserting content? Is there a keyboard shortcut or something else
I found a way to visualise any tab using TabHost in the UI Designer. Is probably not the best way, but it works.
1. Go to the Component Tree, where you have all the elements of the UI.
2. Inside the FrameLayout that TabHost automatically creates for you, there are the tabs.
3. If you change the order of the tabs just drag and dropping in the Component Tree, you get to see the one that is placed in the first position.
UPDATE:
According to this answer there is no way to change the tabs of a TabHost. That question refers to IntelliJ; I don't know if it applies to Android Studio.
Also, it seems that TabHost has been replaced by FragmentActivity and ActionBar. See Android how can i replace the deprecated tabhost? for a discussion.
It is defined as "Select next Tab in multi-editor file" in Settings -> Keymap.
On Windows it seems to default to CRTL+SHIFT+RIGHT/LEFT or ALT+SHIFT+RIGHT/LEFT. On my Mac it defaults to CTRL+SHIFT+RIGHT/LEFT.
Note that Studio doesn't allow the default Keymap to be edited so you will first need to copy the default and give it a new name.
Also see Shortcut to switch between design and text in android studio.
By mouse, select the FrameLayout then long left click on any space in it.

Resources