コード例 #1
0
        public override ITextStrategy Clone()
        {
            TextGradOutlineStrategy p = new TextGradOutlineStrategy();
            if (m_bClrText)
                p.Init(m_clrText, m_clrOutline1, m_clrOutline2, m_nThickness);
            else
                p.Init(m_brushText, m_clrOutline1, m_clrOutline2, m_nThickness);

            return (ITextStrategy)(p);
        }
コード例 #2
0
ファイル: Canvas.cs プロジェクト: amikey/outline-text
        /// <summary>
        /// Setting Gradient Outlined Text effect
        /// </summary>
        /// <param name="brushText">is the text brush</param>
        /// <param name="clrOutline1">is the inner outline color</param>
        /// <param name="clrOutline2">is the outer outline color</param>
        /// <param name="nThickness">is the outline thickness</param>
        /// <returns>valid ITextStrategy pointer if successful</returns>
        public static ITextStrategy TextGradOutline(
            System.Drawing.Brush brushText,
            System.Drawing.Color clrOutline1,
            System.Drawing.Color clrOutline2,
            int nThickness)
        {
            TextGradOutlineStrategy strat = new TextGradOutlineStrategy();

            strat.Init(brushText, clrOutline1, clrOutline2, nThickness);

            return(strat);
        }
コード例 #3
0
        /// <summary>
        /// Setting Gradient Outlined Text effect
        /// </summary>
        /// <param name="clrText">is the text color</param>
        /// <param name="clrOutline1">is the inner outline color</param>
        /// <param name="clrOutline2">is the outer outline color</param>
        /// <param name="nThickness">is the outline thickness</param>
        /// <returns>valid ITextStrategy pointer if successful</returns>
        public static ITextStrategy TextGradOutline(
            System.Drawing.Color clrText,
            System.Drawing.Color clrOutline1,
            System.Drawing.Color clrOutline2,
            int nThickness,
            GradientType gradType)
        {
            TextGradOutlineStrategy strat = new TextGradOutlineStrategy();

            strat.Init(clrText, clrOutline1, clrOutline2, nThickness, gradType);

            return(strat);
        }
コード例 #4
0
        public override ITextStrategy Clone()
        {
            TextGradOutlineStrategy p = new TextGradOutlineStrategy();

            if (m_bClrText)
            {
                p.Init(m_clrText, m_clrOutline1, m_clrOutline2, m_nThickness);
            }
            else
            {
                p.Init(m_brushText, m_clrOutline1, m_clrOutline2, m_nThickness);
            }

            return((ITextStrategy)(p));
        }
コード例 #5
0
ファイル: Canvas.cs プロジェクト: shaovoon/outline-text
        /// <summary>
        /// Setting Gradient Outlined Text effect
        /// </summary>
        /// <param name="brushText">is the text brush</param>
        /// <param name="clrOutline1">is the inner outline color</param>
        /// <param name="clrOutline2">is the outer outline color</param>
        /// <param name="nThickness">is the outline thickness</param>
        /// <returns>valid ITextStrategy pointer if successful</returns>
        public static ITextStrategy TextGradOutline(
            System.Drawing.Brush brushText,
            System.Drawing.Color clrOutline1,
            System.Drawing.Color clrOutline2,
            int nThickness)
        {
            TextGradOutlineStrategy strat = new TextGradOutlineStrategy();
            strat.Init(brushText, clrOutline1, clrOutline2, nThickness);

            return strat;
        }
コード例 #6
0
ファイル: OutlineText.cs プロジェクト: shaovoon/outline-text
        public void TextGradOutline(
            System.Drawing.Brush brushText,
            System.Drawing.Color clrOutline1,
            System.Drawing.Color clrOutline2,
            int nThickness)
        {
            TextGradOutlineStrategy pStrat = new TextGradOutlineStrategy();
            pStrat.Init(brushText, clrOutline1, clrOutline2, nThickness);

            m_pTextStrategy = pStrat;
        }