コード例 #1
0
        void Attach()
        {
            _textProperty.Attach(OnTextChanged);
            _isPasswordProperty.Attach(OnTextChanged);
            _internalTextProperty.Attach(OnInternalTextChanged);
            _caretIndexProperty.Attach(OnCaretIndexChanged);
            _colorProperty.Attach(OnColorChanged);
            _preferredTextLengthProperty.Attach(OnCompleteLayoutGetsInvalid);

            HasFocusProperty.Attach(OnHasFocusChanged);
            FontFamilyProperty.Attach(OnFontChanged);
            FontSizeProperty.Attach(OnFontChanged);
        }
コード例 #2
0
ファイル: Label.cs プロジェクト: git-thinh/MediaPortal-2
        void Attach()
        {
            _contentProperty.Attach(OnContentChanged);
            _wrapProperty.Attach(OnLayoutPropertyChanged);
            _scrollProperty.Attach(OnLayoutPropertyChanged);

            HorizontalAlignmentProperty.Attach(OnLayoutPropertyChanged);
            VerticalAlignmentProperty.Attach(OnLayoutPropertyChanged);
            FontFamilyProperty.Attach(OnFontChanged);
            FontSizeProperty.Attach(OnFontChanged);

            HorizontalContentAlignmentProperty.Attach(OnLayoutPropertyChanged);
            VerticalContentAlignmentProperty.Attach(OnLayoutPropertyChanged);
        }