473,385 Members | 1,893 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

Translucent form, opaque text.

As far as I know if I change the form's opacity, every control on the
form also inherits that opacity. But in many real applications (not
application programs), we see opaque text (100% opacity) on a
traslucent background, for example text messages on TV. Or look at the
title bar text of Aero. Background is translucent but the text is
opaque.

Is it possible to use 100% opaque text on a traslucent form?
Jul 22 '08 #1
3 4980
On Mon, 21 Jul 2008 17:38:10 -0700, Sin Jeong-hun <ty*******@gmail.com>
wrote:
As far as I know if I change the form's opacity, every control on the
form also inherits that opacity. But in many real applications (not
application programs), we see opaque text (100% opacity) on a
traslucent background, for example text messages on TV. Or look at the
title bar text of Aero. Background is translucent but the text is
opaque.

Is it possible to use 100% opaque text on a traslucent form?
Are you using Forms? WPF?

And, have you tried setting the text opacity explicitly? What happens
when you do?
Jul 22 '08 #2
On Jul 22, 9:41*am, "Peter Duniho" <NpOeStPe...@nnowslpianmk.com>
wrote:
On Mon, 21 Jul 2008 17:38:10 -0700, Sin Jeong-hun <typing...@gmail.com*
wrote:
As far as I know if I change the form's opacity, every control on the
form also inherits that opacity. But in many real applications (not
application programs), we see opaque text (100% opacity) on a
traslucent background, for example text messages on TV. Or look at the
title bar text of Aero. Background is translucent but the text is
opaque.
Is it possible to use 100% opaque text on a traslucent form?

Are you using Forms? *WPF?

And, have you tried setting the text opacity explicitly? *What happens *
when you do?
C# 2.0 forms. As far as I know Windows controls don't have opacity
property but only form does. If I set a form's opacity to 50%, then
the label text's opacity also becomes 50%. I tried to get the form's
DC, and draw text using GDI operations with a color whose A value is
255, but that also didn't work. That A value seemed to be proportional
to the opacity of the form.
Thanks.
Jul 22 '08 #3
On Mon, 21 Jul 2008 17:52:04 -0700, Sin Jeong-hun <ty*******@gmail.com>
wrote:
C# 2.0 forms. As far as I know Windows controls don't have opacity
property but only form does. If I set a form's opacity to 50%, then
the label text's opacity also becomes 50%.
Right, as documented in the Form.Opacity property doc page.

I don't know anything off the top of my head that would allow you to
override that. It seems to me that the property is by design always going
to affect the entire contents of the form.

With a lot of work, you could probably reimplement the opacity stuff, but
giving yourself finer control over the opacity of the contents.

It's possible I'm just missing something...maybe someone else will have
some better ideas.

Pete
Jul 22 '08 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Lloyd Dupont | last post by:
In my C# & MC++ app there is some drawing done through GDI (not +, but win32). I would like to be able to create a translucent HBRUSH. the RGB macro create only solid color... and, anyway,...
0
by: UJ | last post by:
I have a WinForm program that has stuff on the form. I want to add something to it that will have an image over a portion of the window that is translucent. How can I do this? Also - I need to...
0
by: yogi | last post by:
Hi All, I am into a .net compact framework project wherein i need to build the translucent panels using c#. I tried building the same and came out with the solution (using unmanaged code) but i...
0
by: shachar8 | last post by:
hi all. **please excuse my english i'm looking for a way to make my form translucent, so i wolud set it's background image and the form will not look as a common winform(rectangle) but it will...
11
by: Ajith Menon | last post by:
I have created a windows application in which the form needs to be resized on the MouseMove event. The windows resize function takes a lot of CPU cycles. And as the resize function is called on the...
0
by: tristanlbailey | last post by:
I have been attempting to solve this problem for a few weeks now, but I'm not having much luck... I would like to create a seamless fading effect on each form/window in my program; one that, when...
3
scubak1w1
by: scubak1w1 | last post by:
Hello, I posted this in the HTML forum, but it was suggested I post it over here as well by a moderator. I have a form that will not 'fire' in non-IE browsers?? I have poked and poked at the code...
5
by: Prisoner at War | last post by:
On Apr 26, 5:19 pm, Ben C <spams...@spam.eggswrote: Super!! It will take me a while to digest your idea, though...and in the meantime, may I ask: how about utilizing any CSS 2.x methods? And,...
27
by: Nate Eldredge | last post by:
Consider the following pseudo-code: #include <opaque.h> struct foo { int a; opaque_t op; int b; };
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.