Click here to Skip to main content
15,918,808 members
Home / Discussions / C#
   

C#

 
GeneralRe: Paint Event Handler Pin
ZeAugusto21-Jun-06 7:42
ZeAugusto21-Jun-06 7:42 
GeneralRe: Paint Event Handler [modified] Pin
led mike21-Jun-06 8:01
led mike21-Jun-06 8:01 
GeneralRe: Paint Event Handler Pin
Josh Smith21-Jun-06 8:06
Josh Smith21-Jun-06 8:06 
GeneralRe: Paint Event Handler Pin
Jun Du21-Jun-06 9:05
Jun Du21-Jun-06 9:05 
GeneralRe: Paint Event Handler Pin
ZeAugusto21-Jun-06 12:05
ZeAugusto21-Jun-06 12:05 
GeneralRe: Paint Event Handler Pin
Jun Du22-Jun-06 4:27
Jun Du22-Jun-06 4:27 
AnswerRe: Paint Event Handler Pin
led mike21-Jun-06 7:28
led mike21-Jun-06 7:28 
QuestionOpacity Control Pin
Cubzfan21-Jun-06 6:57
Cubzfan21-Jun-06 6:57 
Hi,

My opacity control causes a really bad BLACK flicker after the opacity is initially decreased via the trackbar control. Any ideas on how to get rid of the black flicker would be greatly appreciated.

PS: I tried calling Invalidate and ReDraw after Opacity is adjusted with no luck.

Some of the code...

//
// trackBar1
// Code located on the fader (opacity) control

this.trackBar1.Location = new System.Drawing.Point(26, 14);
this.trackBar1.Maximum = 100;
this.trackBar1.Minimum = 10;
this.trackBar1.LargeChange = 5;
this.trackBar1.SmallChange = 5;
this.trackBar1.Name = "trackBar1";
this.trackBar1.Size = new System.Drawing.Size(220, 45);
this.trackBar1.TabIndex = 0;
this.trackBar1.TickFrequency = 10;
this.trackBar1.TickStyle = System.Windows.Forms.TickStyle.Both;
this.trackBar1.Value = 100;
this.trackBar1.MouseUp += new
System.Windows.Forms.MouseEventHandler(this.TrackBar1_ValueChanged);


private void TrackBar1_ValueChanged(object sender, System.EventArgs e)
{
if (_OpacityChanged != null)//run event
{
_OpacityChanged(this.trackBar1.Value);

}
}

// Code located on the main form. User clicks button to bring up control

private void faderControl_Click(object sender, EventArgs e)
{
FaderControl myFaderControl = new FaderControl();
myFaderControl._OpacityChanged += new
FaderControl.UpdateOpacity(OnOpacityChanged);
myFaderControl.ShowDialog();
}

private void OnOpacityChanged(double OpacityValue)
{
double newOpacityValue = OpacityValue / 100;
this.Opacity = newOpacityValue;

}

AnswerRe: Opacity Control Pin
led mike21-Jun-06 7:27
led mike21-Jun-06 7:27 
GeneralRe: Opacity Control Pin
Cubzfan21-Jun-06 7:32
Cubzfan21-Jun-06 7:32 
GeneralRe: Opacity Control Pin
led mike21-Jun-06 7:41
led mike21-Jun-06 7:41 
GeneralRe: Opacity Control Pin
Cubzfan21-Jun-06 7:51
Cubzfan21-Jun-06 7:51 
GeneralRe: Opacity Control Pin
led mike21-Jun-06 7:59
led mike21-Jun-06 7:59 
GeneralRe: Opacity Control Pin
Cubzfan21-Jun-06 8:07
Cubzfan21-Jun-06 8:07 
GeneralRe: Opacity Control Pin
led mike21-Jun-06 9:29
led mike21-Jun-06 9:29 
QuestionRe: Opacity Control Pin
Dustin Metzgar21-Jun-06 8:33
Dustin Metzgar21-Jun-06 8:33 
AnswerRe: Opacity Control Pin
Cubzfan21-Jun-06 9:31
Cubzfan21-Jun-06 9:31 
GeneralRe: Opacity Control Pin
Dustin Metzgar21-Jun-06 10:04
Dustin Metzgar21-Jun-06 10:04 
GeneralRe: Opacity Control Pin
Cubzfan21-Jun-06 10:10
Cubzfan21-Jun-06 10:10 
GeneralRe: Opacity Control Pin
Alexander Wiseman21-Jun-06 11:59
Alexander Wiseman21-Jun-06 11:59 
GeneralRe: Opacity Control Pin
Cubzfan21-Jun-06 12:17
Cubzfan21-Jun-06 12:17 
GeneralRe: Opacity Control Pin
Alexander Wiseman21-Jun-06 13:11
Alexander Wiseman21-Jun-06 13:11 
GeneralRe: Opacity Control Pin
Cubzfan21-Jun-06 13:52
Cubzfan21-Jun-06 13:52 
GeneralRe: Opacity Control Pin
Cubzfan22-Jun-06 3:58
Cubzfan22-Jun-06 3:58 
GeneralRe: Opacity Control Pin
Dustin Metzgar22-Jun-06 4:24
Dustin Metzgar22-Jun-06 4:24 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.