windows phone light theme making textboxes invisible - windows-phone-7

I want to app background to black only so i put black background image to all the pages grids..
now the problem is when phone is running on dark theme everything is perfect but if it is running on light theme then all the things (most of them) are invisible now because when there is light theme phone changes the colors to go dark & because of black background its invisible
so I set the manual colors to all the things which makes most of the things visible now but still when i click on textbox it gets dark
is there any solution where i can keep my black background & still have everything visible in light theme?

You can use Jeff Wilcox theme manager or otherwise you will need to edit the Style of all the control yourself to force the Dark theme colors.
If you want to edit all the Style manually, you can retrieve all the Black them colors from C:\Program Files (x86)\Microsoft SDKs\Windows Phone\v7.1\Design\DarkBlue\ThemeResources.xaml and add them to your project App.xaml.

Related

PhoneCallTask alert color change in windows phone 7 & 8

I am forcing my application only to be in light theme this means even if you select the dark theme from phone settings, you can not see the dark theme. I am pragmatically finding the theme and changing all the styles in to white theme.
I want my UI in white theme, all the controls, popup, etc will be in white theme.
I am using the PhoneCallTask, the popup is coming up as usual but in dark theme it is showing the black popup, i want the popup color as white color even though dark theme is selected.
There is nothing you can do about it. You can force your app to use the white theme, but you cannot for the system "parts" to do so, not even the keyboard.

Automatic Dark/Light Icon Support in Windows Phone 8

I think this is a very common problem, but I cannot find a suitable solution for me. As you all know, WP supports a dark and a light theme. The user can change the theme and there are ways to override his decision and to display everything in the color theme you've selected. However, I'm just trying to react to this two theme types and I want to display icons in the correct color.
If you use the Application Bar, you can select from many built in icons, which will be automatically inverted from light to dark and vice versa.
Why isn't there any support for normal images? For example: I want to display a telephone icon. I've picked one from the built in icons and copied it from the Microsoft SDK folder to the Image folder of my project. If the user uses the dark theme, everything will be fine because the white telephone icon will be visible on the black background. But if he switches to the light theme, the icon will be invisible because it is white on white.
I'm fully aware of the style resources for textboxes or background colors, which use the phone's accent or theme color. But why is it, that there is no support for simple icons which I added as Image to my XAML page?
Of course I could detect in the constructor of the page if the user is in dark or light mode. I would then load either a black or white version of the telephone icon. But this check will be done everytime I visit the page and slows everything down. It's also annoying to manually add the check for the theme each time I'm adding a theme aware image.
Is there any solution, which will work with XAML only? Or is at least easy to maintain? And why can't I use the built in images from the SDK right from the beginning? They are already available in dark and light versions and are already used in the application bar.
If you want the icon to function like in the actionbar, just be white (if dark theme) and black (if light theme) then you can add the image as an opacity mask to a rectangle, like this:
<Rectangle Fill="{StaticResource PhoneForegroundBrush}" Width="48" Height="48" >
<Rectangle.OpacityMask>
<ImageBrush ImageSource="/Images/my.icon.png" />
</Rectangle.OpacityMask>
</Rectangle>
Where my.icon.png is a white image, like those you can choose for the actionbar.
You could use vector graphics instead of bitmap icons and use a theme-aware brush to draw them.
If you want the App to respond to a switch of the theme you'll need to respond to it any way.
I added a property to the base class of my Views that returns the selected theme. That way I can use/bind to that value.
It is also possible to use a ValueConverter that turns a logical name of a resource into a name of a theme specific resource.
Edit
Have a look at this: Custom light/dark theme resources on Windows Phone 7
Detect the theme (Supporting dark and light themes gives the best solution for this, I think), and then set the image accordingly. If you do this a lot, a custom control where you can supply two image sources and the correct one gets used would be easy enough to create.
Edit: Here's another good article on this topic. New Screen Resolutions
You pick a White Foregrounded icon use it. It suits for both Light and Dark themes. Thats what I have been doing.
The Coding 4 Fun control toolkit includes a round button that mimics the application bar buttons, including updating the foreground color depending on the theme. The code is open source, so perhaps you might find an answer in there. Or, as a hack, you could use the RoundButton control, turn off the border, and not provide a Click event.

Windows Phone 7.1 Light/Dark themes management

How does exactly work themes switching in application? What if I override the default styles? Can I also define different styles for light and dark themes separately? Why the icons colos get changed - i.e. the black background of icons changes into white if the theme is set to Dark. Will it also be changed to white if I override the background style of application bar to white explicitly? How can I make sure nothing gets changed and my app looks the same in Light and Dark themes?
Have you seen these?
Theme Overview for Windows Phone
http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff402557(v=vs.105).aspx
Theme Resources for Windows Phone
http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff769552(v=vs.105).aspx
How to: Apply Theme Resources for Windows Phone
http://msdn.microsoft.com/en-us/library/windowsphone/develop/ff769545(v=vs.105).aspx
I personally use PhoneThemeManager from Jeff Wilcox for theme overriding works!
Of course, it is better to have the same UX across all the Windows Phone application when it comes to light/dark theme support, but I agree that sometimes it is really needed to override the theme.
You can probably find more information in this thread: How to override WindowsPhone dark theme by light
and also previously I was using this tutorial to customize light and dark themes:
http://blog.richardszalay.com/2011/06/11/practical-support-for-light-dark-themes-on-windows-phone-7/

WP emulator theme change

Everytime WP emulator starts,it has dark theme with red color. I prefer it to have light theme and lime color.
Is there any way i can make those changes permanent so that next time emulator starts, it picks up what settings i want.
Sadly there is no way to make it persist settings.
However, you should use the dark theme as default, and then test with the white theme from time to time, since that best represents the consumers.

Change Application Bar icon color in light theme - Windows Phone 7

I have a favourite icon on the ApplicationBar that I want to change to yellow image when the item is favourited. This works well on Dark Theme but when the user change to White Theme, it becomes black all the time. Actually, the color changes to yellow for around 1 second and then change to black.
I am testing on Windows Phone 7 Emulator, not test with device yet
The best answer I have found for this so far is from the UI Design and Integration Guide for Windows Phone 7 v2.0. It says colored icons cause the Application Bar to display unpredictably.
Extract below:
"Application Bar Icon images should be 48 pixels by 48 pixels and have a white foreground on a transparent background using an alpha channel. The Application Bar will colorize the icon according to the current style settings and colored icons can cause this effect to display unpredictably."

Resources