How to remove Window 11 Start Menus bloatwares via Powershell? - powershell

In the new Windows 11 Start Menus, there are apps like "TikTok" and "Prime Videos" that are not actually installed on the system, they would start installing when you clicked on the icon. This means that usual way of uninstalling via Powershell (ie: Remove-AppxPackages) does not work. In Window 10, I would get a round this by just replacing the orginal Start Menus layout config file with a blank one (effectively remove all pinned apps), then manually repin all the apps I wanted; but, this does not works on Win11 either.
So... does anyone know how to remove all of this visual bloats on the Start Menus via PowerShell (or any other command-line tools/languages, for that matter)?

Related

How to get native windows decorations on GTK3 on Windows 7+ and MSYS2

I am trying to port my application from linux to windows and I have a problem with theming. In linux this works out of a box, just compile it and application is using good theme and looks native.
I have installed gtkmm3 and gtk3 in MSYS2 and I am building it with CMake. This is OK, I had to copy all dlls to directory with binary to be able to execute it. I did not copy anything else. I am trying to create "unzip and execute" package.
My problem is, that application looks out of place. It does not look native at all. There are shadows around the window, which is fine in Windows10, but in Windows 7 it looks not native. Also several icons are missing.
Even gitk3-demo looks non-native in the same way (but it has at least the minimize/maximize/close icons correct).
So the question is: How can I achieve native look of GTK3 application on Windows? Or at least native window decorations?
Thanks
Thera are two sub-problems: missing icons and setting right theme.
Missing icons
For missing icons it was enough to copy these icons
window-close-symbolic.symbolic.png
window-maximize-symbolic.symbolic.png
window-minimize-symbolic.symbolic.png
from: C:\msys64\mingw32\share\icons\Adwaita\22x22\actions
to: "your executable folder"\share\icons\Adwaita\22x22\actions
Theme
Using win32 native theme
There is actually a built-in native-like theme in GTK3. For using native-like theme just create file "your executable folder"\etc\gtk-3.0\settings.ini with this in it
[Settings]
gtk-theme-name=win32
win32 theme is built in into GTK3 and only three icons from previous step seems to be needed.
On windows 7 this looks as following:
The problem is, that the decorations looks the same even on Windows 10 (including window decorations).
From comment from #andlabs : GTK+ 3 uses the uxtheme.dll APIs to get its Windows look and feel, and unfortunately Microsoft has kept those Windows 7-like for window borders. (more in comments)
You can see Windows 10 Gtk3 application with win32 theme here:
Using non default theme
And if you are not happy with default or win32 theme, you can use custom themes (like this Flat-Pat) from the internet. :) In order to do it you need to create config file:
"your executable folder"\etc\gtk-3.0\settings.ini with this in it
[Settings]
gtk-theme-name=Flat-Plat
and you need to copy the theme files to directory in path of your executable
"your executable folder"\share\themes\Flat-Plat
in that folder, the index.theme file and gtk-x.x folders should be present. Obviously gtk-theme-name and folder name should match.
After you run the executable you should be able to get different theme.
EDIT: So there is a win32 theme built-in, thank you #andlabs
EDIT2: Added screenshots
EDIT3: Added Windows 10 screenshot and corrected facts.
You can set GTK_CSD=0 environment variable to disable client-side window decorations and enable Windows native decorations, which gets rid of the ugly win7-like titlebar, as well as Adwaita-like one.
Actually, Gtk+3 been compatible with Windows 10 and you can use the native windows theme by making this your default theme.
gtk-theme-name = MS-Windows
For people like me who use (activestate) perl, the /share and /etc need to be placed one directory above the perl.exe (say in C:\Perl64 if perl.exe is in C:\Perl64\bin).
While GTK_CSD=0 is doing a fine job for windows frame icons, it seams that default Drag-And-Drop (DND) icons are missing too.
Dragging GtkEntry or GtkTreeView contents shows a drag-icon.
I've prepared a button as drag source under Gtk+-3.24.4. When dragging the button, the mouse cursor disappears and no drag icon is shown.
When using gtk_drag_source_set_icon_pixbuf(bt, pixbuf), the pixbuf appears as drag icon. But doing it this way is only half the job done, because move/copy indicators are missing on the icon.

Can't change PowerShell font and window size on Windows 8.1

My PowerShell window opens with a very small font (and window size). This is a common problem, and I found a bunch of suggestions for how to deal with it, but none of the suggestions seem to work. Specifically, the common suggestion that one should open PowerShell with admin privileges, change the properties, and then close the window, doesn't work. It's still small the next time I open it. The only way I managed to get it to open with the right font and window size, was by opening the application directly. Any invocation via a shortcut doesn't give the right properties.
I'm running Windows 8.1, which seems to be the main difference between my situation and that of the other users who had this problem. Any idea how to fix this?
For Windows 8.1, in Start, find PowerShell.
Open file location. Open shortcut Properties (right click menu). Security tab → Edit your permissions to Modify.
Select Font tab (skip errors - nothing is set hence the problem). Select Font (I set Lucida Sans Size 16).
Apply (changes). Security tab Edit permissions remove modify. Apply. All done.
Is it possible that you are adjusting the Properties rather than the 'Defaults'? Also, I am with Keith; the Consolas fonts give you much large sizes than the Raster, and the Lucida Console give people problems.
I'm on Windows 8.1 and the only thing I ever do is start PowerShell via its shortcut then edit the console properties to my liking. I then launch PowerShell elevated and set the same settings. Usually that has me pretty well covered on Windows 8.1. Of course, if you then launch the x86 console for PowerShell you may need to configure it as well.
I had the same problem. As stated here I select a non-12pt font, and it works. So I choose 14 pt Consolas. And it works. I'm using Windows 7 and Windows Server 2012. Both acts like the same.
Run PowerShell as Administrator, set the default font properties, and close the PowerShell window.
Then run PowerShell as the normal user, and you should see the same font as you did before.

Powershell ISE Doesn't Render the Client Area in Windows 7

Recently, the Powershell ISE on my Windows 7 laptop developed a problem in which only the title bar and frame would render to the screen. The entire client area (including menus) doesn't appear. Instead, whatever is behind the client area shows through. If I move the ISE around on the screen I get a client area with a jumble of pieces of the desktop or other apps that I drag the ISE over, as well as some ISE frame pieces.
I can blindly click in the area where I think the menu should be, and can occasionally get something to appear (a Save As... dialog, or some such), but the menus themselves are never drawn.
This started sometime during a period in which I didn't use the ISE, so I've no idea how many updates may have been automatically downloaded or pushed to my machine by my IT folks, and since I've no idea when it started happening they can't tell me anything either.
Any ideas on why a Windows 7 app in general or the ISE in particular could have this issue?
Could be video card drivers. Try disabling windows areo to see if it's 3D driver related:
net stop uxsms
Also try running ISE as administrator.
On my system it's an interaction with MaxiVista (www.maxivista.com) which allows me to use an old laptop as a second monitor.
When the second (Maxivista) monitor is enabled, the Powershell ISE does not draw properly. So #BryanVine is right. It's to do with video drivers.

Eclipse IDE - Is it possible to have detached windows not always on top?

Basically I have multiple monitors for development with Eclipse. I detach some of the windows such as the "Console" view so that I can have it fill my monitor. This is great as I can fill up my screens.
However in some cases I also want to have my browser in front while I'm coding since there's some documentation I need to look at. I can't figure out how to do this without creating another perspective...
You can open a new window (Window|New Window) and drag your views into this window instead of detaching them. New windows are not connected with the main one and you can control their visibility as you wish.
The answer appears to be that you can't...
In Eclipse Luna I had the problem that floating windows were not coming up while setting the focus on the main IDE window. It happened after I changed from 32 to 64bit using the same workspace. The windows were opened and closed correctly.
What solved the problem was reintegrating the floating windows into the main IDE window and recreated floating windows again.

Is it possible to save a window layout in Windows XP?

When I am working with files on my project I normally have four windows open viewing four different folders in the four quadrants of the screen. My morning ritual involves having to manually open these four folders, takes only a few moments but I was hoping to find a way to automate this with Windows XP?
Any ideas?
You can write a batch file with these commands:
start c:\myfolder1
start c:\myfolder2
start c:\myfolder3
start c:\myfolder4
or, since Bart said in the comments on this answer, he uses this method:
explorer c:\myfolder1 (etc...)
and then run that any way you wish (on Start up, via a shortcut...)
As for saving their position on the screen, I don't know much about that, but you could try using Winsplit Revolution. That will let you use hotkeys to reposition windows (Ctrl+Alt+Numpad 7 moves a window to the top left).