begin process at 2010 02 10 03:54:52
  Trouver un code source :
 
dans
 
Accueil > 

Code

 > 

Applications

 > FENETRE TRANSPARENTE

FENETRE TRANSPARENTE


 Information sur la source

Note :
9 / 10 - par 2 personnes
9,00 / 10

  • 1

  • 2

  • 3

  • 4

  • 5

  • 6

  • 7

  • 8

  • 9

  • 10
Catégorie :Applications Source .NET ( DotNet ) Classé sous :transparence, opacity Niveau :Débutant Date de création :11/08/2002 Date de mise à jour :11/08/2002 08:29:54 Vu / téléchargé :11 297 / 607

Auteur : omi

Ecrire un message privé
Commentaire sur cette source (1)
Ajouter un commentaire et/ou une note

 Description

Juste une petite fenetre dans laquelle vous pouvez regler la transparance.
Code sous visual studio .NET beta 2.

Source

  • using System;
  • using System.Drawing;
  • using System.Collections;
  • using System.ComponentModel;
  • using System.Windows.Forms;
  • using System.Data;
  • namespace test_opacite
  • {
  • /// <summary>
  • /// Summary description for Form1.
  • /// </summary>
  • public class Form1 : System.Windows.Forms.Form
  • {
  • private System.Windows.Forms.TrackBar trackBar1;
  • private System.Windows.Forms.TextBox textBox1;
  • private System.Windows.Forms.Button button1;
  • private System.Windows.Forms.Label label1;
  • /// <summary>
  • /// Required designer variable.
  • /// </summary>
  • private System.ComponentModel.Container components = null;
  • public Form1()
  • {
  • //
  • // Required for Windows Form Designer support
  • //
  • InitializeComponent();
  • //
  • // TODO: Add any constructor code after InitializeComponent call
  • //
  • }
  • /// <summary>
  • /// Clean up any resources being used.
  • /// </summary>
  • protected override void Dispose( bool disposing )
  • {
  • if( disposing )
  • {
  • if (components != null)
  • {
  • components.Dispose();
  • }
  • }
  • base.Dispose( disposing );
  • }
  • #region Windows Form Designer generated code
  • /// <summary>
  • /// Required method for Designer support - do not modify
  • /// the contents of this method with the code editor.
  • /// </summary>
  • private void InitializeComponent()
  • {
  • this.label1 = new System.Windows.Forms.Label();
  • this.textBox1 = new System.Windows.Forms.TextBox();
  • this.button1 = new System.Windows.Forms.Button();
  • this.trackBar1 = new System.Windows.Forms.TrackBar();
  • ((System.ComponentModel.ISupportInitialize)(this.trackBar1)).BeginInit();
  • this.SuspendLayout();
  • //
  • // label1
  • //
  • this.label1.Location = new System.Drawing.Point(32, 16);
  • this.label1.Name = "label1";
  • this.label1.Size = new System.Drawing.Size(88, 16);
  • this.label1.TabIndex = 3;
  • this.label1.Text = "Opacité :";
  • //
  • // textBox1
  • //
  • this.textBox1.Location = new System.Drawing.Point(24, 40);
  • this.textBox1.Name = "textBox1";
  • this.textBox1.TabIndex = 1;
  • this.textBox1.Text = "100 %";
  • //
  • // button1
  • //
  • this.button1.Anchor = (System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right);
  • this.button1.Location = new System.Drawing.Point(288, 24);
  • this.button1.Name = "button1";
  • this.button1.Size = new System.Drawing.Size(75, 32);
  • this.button1.TabIndex = 2;
  • this.button1.Text = "Quitter";
  • this.button1.Click += new System.EventHandler(this.Quitter);
  • //
  • // trackBar1
  • //
  • this.trackBar1.Dock = System.Windows.Forms.DockStyle.Bottom;
  • this.trackBar1.LargeChange = 10;
  • this.trackBar1.Location = new System.Drawing.Point(0, 73);
  • this.trackBar1.Maximum = 100;
  • this.trackBar1.Minimum = 5;
  • this.trackBar1.Name = "trackBar1";
  • this.trackBar1.Size = new System.Drawing.Size(368, 45);
  • this.trackBar1.SmallChange = 5;
  • this.trackBar1.TabIndex = 0;
  • this.trackBar1.TickFrequency = 5;
  • this.trackBar1.Value = 100;
  • this.trackBar1.Scroll += new System.EventHandler(this.RegleOpacite);
  • //
  • // Form1
  • //
  • this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
  • this.ClientSize = new System.Drawing.Size(368, 118);
  • this.Controls.AddRange(new System.Windows.Forms.Control[] {
  • this.label1,
  • this.button1,
  • this.textBox1,
  • this.trackBar1});
  • this.Name = "Form1";
  • this.Text = "Form1";
  • ((System.ComponentModel.ISupportInitialize)(this.trackBar1)).EndInit();
  • this.ResumeLayout(false);
  • }
  • #endregion
  • /// <summary>
  • /// The main entry point for the application.
  • /// </summary>
  • [STAThread]
  • static void Main()
  • {
  • Application.Run(new Form1());
  • }
  • void RegleOpacite(object ob,System.EventArgs ev)
  • //Fonction reglant la transparance
  • {
  • this.Opacity = ((double)this.trackBar1.Value)/100.0;
  • this.textBox1.Text = this.trackBar1.Value.ToString();
  • }
  • void Quitter(object ob,System.EventArgs ev)
  • {
  • Application.Exit();
  • }
  • }
  • }
using System;
using System.Drawing;
using System.Collections;
using System.ComponentModel;
using System.Windows.Forms;
using System.Data;

namespace test_opacite
{
	/// <summary>
	/// Summary description for Form1.
	/// </summary>
	public class Form1 : System.Windows.Forms.Form
	{
		private System.Windows.Forms.TrackBar trackBar1;
		private System.Windows.Forms.TextBox textBox1;
		private System.Windows.Forms.Button button1;
		private System.Windows.Forms.Label label1;
		/// <summary>
		/// Required designer variable.
		/// </summary>
		private System.ComponentModel.Container components = null;

		public Form1()
		{
			//
			// Required for Windows Form Designer support
			//
			InitializeComponent();

			//
			// TODO: Add any constructor code after InitializeComponent call
			//
		}

		/// <summary>
		/// Clean up any resources being used.
		/// </summary>
		protected override void Dispose( bool disposing )
		{
			if( disposing )
			{
				if (components != null) 
				{
					components.Dispose();
				}
			}
			base.Dispose( disposing );
		}

		#region Windows Form Designer generated code
		/// <summary>
		/// Required method for Designer support - do not modify
		/// the contents of this method with the code editor.
		/// </summary>
		private void InitializeComponent()
		{
			this.label1 = new System.Windows.Forms.Label();
			this.textBox1 = new System.Windows.Forms.TextBox();
			this.button1 = new System.Windows.Forms.Button();
			this.trackBar1 = new System.Windows.Forms.TrackBar();
			((System.ComponentModel.ISupportInitialize)(this.trackBar1)).BeginInit();
			this.SuspendLayout();
			// 
			// label1
			// 
			this.label1.Location = new System.Drawing.Point(32, 16);
			this.label1.Name = "label1";
			this.label1.Size = new System.Drawing.Size(88, 16);
			this.label1.TabIndex = 3;
			this.label1.Text = "Opacité :";
			// 
			// textBox1
			// 
			this.textBox1.Location = new System.Drawing.Point(24, 40);
			this.textBox1.Name = "textBox1";
			this.textBox1.TabIndex = 1;
			this.textBox1.Text = "100 %";
			// 
			// button1
			// 
			this.button1.Anchor = (System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right);
			this.button1.Location = new System.Drawing.Point(288, 24);
			this.button1.Name = "button1";
			this.button1.Size = new System.Drawing.Size(75, 32);
			this.button1.TabIndex = 2;
			this.button1.Text = "Quitter";
			this.button1.Click += new System.EventHandler(this.Quitter);
			// 
			// trackBar1
			// 
			this.trackBar1.Dock = System.Windows.Forms.DockStyle.Bottom;
			this.trackBar1.LargeChange = 10;
			this.trackBar1.Location = new System.Drawing.Point(0, 73);
			this.trackBar1.Maximum = 100;
			this.trackBar1.Minimum = 5;
			this.trackBar1.Name = "trackBar1";
			this.trackBar1.Size = new System.Drawing.Size(368, 45);
			this.trackBar1.SmallChange = 5;
			this.trackBar1.TabIndex = 0;
			this.trackBar1.TickFrequency = 5;
			this.trackBar1.Value = 100;
			this.trackBar1.Scroll += new System.EventHandler(this.RegleOpacite);
			// 
			// Form1
			// 
			this.AutoScaleBaseSize = new System.Drawing.Size(5, 13);
			this.ClientSize = new System.Drawing.Size(368, 118);
			this.Controls.AddRange(new System.Windows.Forms.Control[] {
																		  this.label1,
																		  this.button1,
																		  this.textBox1,
																		  this.trackBar1});
			this.Name = "Form1";
			this.Text = "Form1";
			((System.ComponentModel.ISupportInitialize)(this.trackBar1)).EndInit();
			this.ResumeLayout(false);

		}
		#endregion

		/// <summary>
		/// The main entry point for the application.
		/// </summary>
		[STAThread]
		static void Main() 
		{
			Application.Run(new Form1());
		}

		void RegleOpacite(object ob,System.EventArgs ev)
//Fonction reglant la transparance
		{
			this.Opacity = ((double)this.trackBar1.Value)/100.0;
			this.textBox1.Text = this.trackBar1.Value.ToString();
		}

		void Quitter(object ob,System.EventArgs ev)
		{
			Application.Exit();
		}
	}
}


 Fichier Zip

Les Membres Club peuvent télécharger directement un fichier contenu dans le zip sans télécharger le zip en entier !
  •   test opacite
    • test opacite.slnTélécharger ce fichier [Réservé aux membres club]Voir ce fichier933 octets
    • test opacite.suoTélécharger ce fichier [Réservé aux membres club]7 680 octets
    •   test opacite
      • AssemblyInfo.csTélécharger ce fichier [Réservé aux membres club]Voir ce fichier2 426 octets
      • Form1.csTélécharger ce fichier [Réservé aux membres club]Voir ce fichier4 093 octets
      • Form1.resxTélécharger ce fichier [Réservé aux membres club]Voir ce fichier1 790 octets
      • licenses.licxTélécharger ce fichier [Réservé aux membres club]605 octets
      • test opacite.csprojTélécharger ce fichier [Réservé aux membres club]Voir ce fichier3 951 octets
      • test opacite.csproj.userTélécharger ce fichier [Réservé aux membres club]Voir ce fichier1 552 octets
      •   bin
        •   Debug
          • test opacite.exeTélécharger ce fichier [Réservé aux membres club]6 656 octets
          • test opacite.pdbTélécharger ce fichier [Réservé aux membres club]15 872 octets
      •   obj
        •   Debug
          • test opacite.exeTélécharger ce fichier [Réservé aux membres club]6 656 octets
          • test opacite.exe.incrTélécharger ce fichier [Réservé aux membres club]2 208 octets
          • test opacite.exe.licensesTélécharger ce fichier [Réservé aux membres club]276 octets
          • test opacite.pdbTélécharger ce fichier [Réservé aux membres club]15 872 octets
          • test opacite.projdataTélécharger ce fichier [Réservé aux membres club]5 000 octets
          • test_opacite.Form1.resourcesTélécharger ce fichier [Réservé aux membres club]320 octets

Télécharger le zip


 Sources de la même categorie

Source avec Zip Source avec une capture Source .NET (Dotnet) RECHERCHE ET GESTION DE FICHIERS PERSONNALISÉES par JeremyLecouvert
Source avec une capture DEFORMÉE D'UNE POUTRE par keiz
Source avec Zip Source avec une capture OUTLOOK RESILIENCY CLEANER par Safti
Source avec Zip Source avec une capture Source .NET (Dotnet) COLORCOMBOBOX, COMBO BOX PERMETTANT DE SÉLECTIONNER DES COUL... par manshivas
Source avec Zip Source avec une capture Source .NET (Dotnet) YREGEXTER - THE REGEX TESTER par pysco68

 Sources en rapport avec celle ci

Source avec Zip Source avec une capture Source .NET (Dotnet) DOCK CIRCULAIRE AVEC EFFET , AVEC TRAITEMENT IMAGE ET TRANSP... par NetWedge
Source avec Zip Source .NET (Dotnet) [DÉBUTANTS] ANIMATION DES FENETRES, CHARME SPÉCIALE POUR VOT... par boutemine
Source .NET (Dotnet) RENDRE UNE FENETRE TRANSPARENTE EN CAS DE DÉPLACEMENT DE CEL... par sephiro
Source avec Zip Source avec une capture Source .NET (Dotnet) ILLUSION - TEXTURES D'OPACITÉ VARIABLE (OPENGL) par Zap
Source avec Zip Source .NET (Dotnet) OPACITE ET SAUVEGARDE DE BOITE DE TEXT par neogally

Commentaires et avis

Commentaire de Hadrien64 le 27/07/2003 12:10:53

pssss transparente !

 Ajouter un commentaire


Discussions en rapport avec ce code source dans le forum

Transparence d'une fenetre via une autre. [ par bigflo93 ] Bonjour,Je cherche de l'aide sur la transparence d'un Form via un autre Form.J'ai un Form avec un menu Option dans le mainMenu.Lorsque je clique dessu Contour en transparence d'un BMP sur un Forme [ par JCpp ] J'ai réalisé une petite interface en BMP avec un fond blanc.Je n'arrive pas à obtenir le résultat voulu, comme par exemple le «Windows Media Player». comment gerer la transparence avec les texture [ par nidk ] bonjour a tous, voila je m'amuse un peu avec directx ,j'ai compris pas mal de chose.Mais je bloque a la transparence.J'ai compris cmt activer la cou Transparence continuelle ? [ par Kedaessa ] Salut !Je voudrais savoir si c'est possible q'une image chargée à partir d'un fichier ait une transparence continuelle, c'est à dire au chargement pui [WinForm] [PictureBox] transparence [ par stailer ] Salut tout le monde,J'ai un problème avec les PictureBox :Je mets un picturebox sur une form avec une image... Je rajoute un picturebox avec comme bac [C#] Visual 2003 -> Visual 2005 [ par scoubidou944 ] Je suis en train de testerl a version 2005 de Visual .NET Whidbey.Alors, premier prog à lancer et ca plante :( dans mon splash screen.En gros j'ai un Controls - Transparence sur un control [ par bucherb ] Hello!Alors voilà, il semblerait quand dans le framework, la couleur Transparente sur un control affiche se qui se trouve sur son container, c'est à d Image et transparence [ par MorpionMx ] Bonsoir a tous, J'aurais besoin de votre aide. En fait voila, j'ai une image, contenant des zones noires et blanches. Le but serait d'appliquer, a Transparence et WinForm [ par th_vador ] Bonjour &#224; tous.Je vous soumet un petit probl&#232;me que je rencontre avec Visual C# express. Je veux donner &#224; une WinForm une forme sp&#233 [C#] Picture box & transparence [ par scoubidou944 ] (juste pour info, le theme Graphique a une erreur dans son &#233;criture (Graphqiue)) J'ai une picture box. A partie de %WINDIR%/system32/wscui.cpl j


Nos sponsors


Sondage...

Comparez les prix

CalendriCode

Février 2010
LMMJVSD
1234567
891011121314
15161718192021
22232425262728

Consulter la suite du CalendriCode

 
Développement réalisé par Nicolas SOREL (Nix) avec l'aide de : Cyril DURAND et Emmanuel (EBArtSoft), Merci à Vincent pour ses précieux conseils.
CodeS-SourceS.com© Toute reproduction même partielle est interdite sauf accord écrit du Webmaster
CodeS-SourceS.com© est une marque déposée tous droits réservés

Google Coop CodeS-SourceS Google Coop CodeS-SourceS
Temps d'éxécution de la page : 0,624 sec (3)

Nous contacter | Annoncer sur CodeS-SourceS | Mentions légales