コード例 #1
0
ファイル: MarqueeStrip.xaml.cs プロジェクト: afrog33k/eAd
        void AttachMarquee(SigMarquee Amarquee = null)
        {
            if(Amarquee==null)
                Amarquee= new SigMarquee();
            Marquee = Amarquee;

            //TextBanner.FontFamily = Marquee.font.Family;
            TextBanner.FontSize = Marquee.Font.Size;
            //TextBanner.Foreground =  new SolidColorBrush(Marquee.font.ForeColor);
            TextBanner.FontWeight = Marquee.Font.Weight;
            //TextBanner.FontStyle = Marquee.font.Style;
            TextBanner.Text = Marquee.Message;
            
            TextBanner.Width = Marquee.IsVerticalFlow ? Marquee.Font.Size : double.NaN;

            Background = new SolidColorBrush(Marquee.Font.BackColor);
            if (Marquee.Font.IsGradient)
            {
                bkgPlane.Visibility = Visibility.Visible;
                if (marquee_.IsVerticalFlow)
                    bkgPlane.OpacityMask = Resources["brVBar"] as Brush;
                else
                    bkgPlane.OpacityMask = Resources["brHBar"] as Brush;
            }
            else
            {
         //       bkgPlane.Visibility = Visibility.Hidden;
           //     bkgPlane.OpacityMask = null;
            }

            if (Marquee.IsRemote)
            {
                OnLoopUpdate(null, null);
            }
        }
コード例 #2
0
        public MarqueeStrip(SigMarquee amarquee)
        {
            InitializeComponent();

            AttachMarquee(amarquee == null ? new SigMarquee() : amarquee);
            CompositionTarget.Rendering += Animating;
            //logFile_ = new System.IO.StreamWriter(string.Format("marquee{0}.log", this.GetHashCode()));
        }
コード例 #3
0
ファイル: MarqueeStrip.xaml.cs プロジェクト: afrog33k/eAd
 public MarqueeStrip(SigMarquee amarquee)
 {
     InitializeComponent();
   
     AttachMarquee(amarquee == null ? new SigMarquee() : amarquee);
     CompositionTarget.Rendering += Animating;
     //logFile_ = new System.IO.StreamWriter(string.Format("marquee{0}.log", this.GetHashCode()));
 }
コード例 #4
0
        void AttachMarquee(SigMarquee Amarquee = null)
        {
            if (Amarquee == null)
            {
                Amarquee = new SigMarquee();
            }
            Marquee = Amarquee;

            //TextBanner.FontFamily = Marquee.font.Family;
            TextBanner.FontSize = Marquee.Font.Size;
            //TextBanner.Foreground =  new SolidColorBrush(Marquee.font.ForeColor);
            TextBanner.FontWeight = Marquee.Font.Weight;
            //TextBanner.FontStyle = Marquee.font.Style;
            TextBanner.Text = Marquee.Message;

            TextBanner.Width = Marquee.IsVerticalFlow ? Marquee.Font.Size : double.NaN;

            Background = new SolidColorBrush(Marquee.Font.BackColor);
            if (Marquee.Font.IsGradient)
            {
                bkgPlane.Visibility = Visibility.Visible;
                if (marquee_.IsVerticalFlow)
                {
                    bkgPlane.OpacityMask = Resources["brVBar"] as Brush;
                }
                else
                {
                    bkgPlane.OpacityMask = Resources["brHBar"] as Brush;
                }
            }
            else
            {
                //       bkgPlane.Visibility = Visibility.Hidden;
                //     bkgPlane.OpacityMask = null;
            }

            if (Marquee.IsRemote)
            {
                OnLoopUpdate(null, null);
            }
        }