예제 #1
0
 public SymbolBox(string templateFileName)
 {
     _SetTemplate(templateFileName);
     _dataContext = new SymbologyContext();
     DataContext = _dataContext;
     HorizontalContentAlignment = HorizontalAlignment.Center;
 }
예제 #2
0
 public SymbolBox()
 {
     _templateFileName = SymbologyManager.DEFAULT_TEMPLATE_NAME;
     Template = SymbologyManager.DefaultTemplate;
     _dataContext = new SymbologyContext();
     DataContext = _dataContext;
     HorizontalContentAlignment = HorizontalAlignment.Center;
 }
예제 #3
0
        /// <summary>
        /// Instantiates new instance of <c>SymbolControl</c> class.
        /// </summary>
        /// <param name="template">Control template.</param>
        public SymbolControl(ControlTemplate template)
        {
            Template = template;

            _dataContext = new SymbologyContext();
            _dataContext.Attributes[SymbologyContext.SIZE_ATTRIBUTE_NAME] = SymbologyManager.DEFAULT_SIZE;
            _dataContext.Attributes[SymbologyContext.FULLSIZE_ATTRIBUTE_NAME] = SymbologyManager.DEFAULT_SIZE + SymbologyManager.DEFAULT_INDENT;
            DataContext = _dataContext;

            HorizontalContentAlignment = HorizontalAlignment.Center;
        }