Any way to draw on the wallpaper in windows 7 with aero enabled? I saw the post for doing it in xp/7 without aero but I'd rather keep it enabled if possible. I also tried the windows 8 approach but that doesn't seem to work in 7 and I can't figure out the correct messages to send.
EDIT:
How to effectively draw on desktop in C#? only works when aero is disabled. When it's enabled the icons and wallpaper are merged so it's impossible to just draw on the wallpaper. The personalization window seems to do it when fading between wallpapers but I've been unable to figure out what to send so far. Replicating the messages Spy++ logs just seems to freeze the wallpaper so it's unable to be changed until explorer is restarted.
Related
Acrylic is by far the best thing in fluent design system, it just makes the app looks so good. And I am totally fine with optimization of it; turning of the transparency when battery is in saving mode.
But I don't want it to be turned off when the user looses the focus over the app. Is there any workarounds for it?
When the user looses the focus over the app, acrylic is turned off and fallback color is used!
Unfortunately acrylic background effect is currently limited to run only when the application window is active, as stated in the documentation
In addition, only background acrylic will replace its transparency and texture with a solid color
When an app window on desktop deactivates
When the UWP app is running on phone, Xbox, HoloLens or tablet mode
I have to say I am a bit shocked the answer to this problem isn't easier to find. I have an application that creates a notification tray icon. When I am running my app on Windows 10 the notification area background color is black. So I am using a white version of my logo for contrast. Running the same program on Windows 7 the taskbar background is dark, but the notification popup has a white background. Thus using my white icon doesn't work?
My first thought was to determine if I am on Windows 10 and if I wasn't to use a blue version of my icons. Sounds simple enough until you try to detect the OS version. For some reason Microsoft has decided that the OSVersion information will just return the Windows 8 version number from now on (if you are on Windows 10)?!?! Seriously? The suggestions to detect Windows 10 are to look at registry keys, or make unsafe calls to kernel level api's?
Other application developers have had to run into this issue. What is the solution? How do you managed your notification tray icons when they have to work when on a white background and black? I would prefer not to make the blue images background white, since the box around the icon won't look very nice.
I'm in the process of porting my App to Windows 8.1 from 8, and had been using the Callisto Settings Flyout in Wide (646 pixel mode).
Windows 8.1 changed the way the Settings work, and a narrow app can now show it's settings, and therefore may be as narrow as 320pixels, which isn't wide enough to hold a wide flyout.
On Windows 8 you could call TryUnsnap() which would make the window wider, but that's deprecated and now does nothing. So what options do I have to make my flyout visible.
I had hoped that because it's a top level window that it would span across the window boundary, but that was wishful thinking.
Having looked around for any Microsoft App that has a wide about box, I finally found one in Xbox Live. It looks as though they're resizing the flyout to the width of the window at the time it's opened.
That's probably a reasonable solution, as long as your flyout has fluid layout.
How does VNC send REPAINT messages to windows even when a user is not active?
I would like to implement this in C sharp - I've had a look at the PrintWindow, SendMessage methods and none of them achieve the same thing as VNC (tested by capturing images and its black) but with VNC I get the full picture.
What techniques are they using to do this and can this be implemented in C sharp to get windows to always repaint even when a user is not active (i.e. RDP is closed, minimised or similar).
Thanks all
You could use the technique used by video games, which consists in redrawing permanently a window during CPU idle time.
I found a C# implementation here.
You just have to adapt it to your needs.
VNC does NOT send WM_PAINT messages
Windows does (and it does not care whether a user is active). See also
Is it possible to screenshot a minimized application
How to get the screenshot of a minimized application programmatically?
Capturing screenshots of a minimized remote desktop
How to programatically change the color scheme using c#? I want to change the color scheme to windows vista basic or windows 7 basic. How can I do that?
Thanks,
Nikil.
You can change the theme of the system using SetSystemVisualStyle method.
Link to pInvoke SetSystemVisualStyle.
C# Sample usage:
// This will set your Visual Style to Luna
SetSystemVisualStyle(#"C:\WINDOWS\resources\Themes\Luna\Luna.msstyles", "Metallic", "NormalSize", 0);
This is what worked best for me. With my very graphics-intensive program, Windows Vista and 7 eventually forced the system back into Windows Basic Colors. But if I minimized or maximized an MDI window before that happened, everything locked up totally. I had to hold the power button for 5 seconds to shut it down and then reboot. Here is what I found to go to Windows Basic Colors near the start of program execution:
using System.Runtime.InteropServices;
//1-9-2013: so we can DISABLE COMPOSITING -- forcing Windows "Aero Glass" to revert to "Aero Basic"
[DllImport("dwmapi.dll", PreserveSig = false)]
public static extern void DwmEnableComposition(bool bEnable);
DwmEnableComposition(false); //DISABLE COMPOSITING -- forces Windows "Aero Glass" to revert to "Aero Basic"
The change to Aero Basic is for Windows itself, affecting all running programs. System reverts to "Aero Glass" upon exit of this app. There might be other side effects, but so far, it's running well for me.
P.S. Looks like this is deprecated in Windows 8 and does nothing except return a True. My app is a real-time monitoring program with nothing else on the machine, so I'm comfortable forcing Windows Basic Colors. So this is a work-around, until I can locate what in my app is chewing up so many machine cycles with Aero Glass.