/// <summary>
		/// setup the given control's WritingSystem[Factory] and Stylesheet related functionality
		/// </summary>
		/// <param name="control"></param>
		/// <param name="cache"></param>
		/// <param name="mediator">used to get stylesheet</param>
		/// <param name="wsDefault">used to set WritingSytemCode and Font for the control</param>
		public static void SetupWritingSystemAndStylesheetInfo(IWritingSystemAndStylesheet control,
			FdoCache cache, Mediator mediator, int wsDefault)
		{
			control.WritingSystemFactory = cache.LanguageWritingSystemFactoryAccessor;
			control.WritingSystemCode = wsDefault;
			control.Font = new System.Drawing.Font(cache.LangProject.GetDefaultFontForWs(wsDefault), 10);
			control.StyleSheet = FontHeightAdjuster.StyleSheetFromMediator(mediator);
		}
		/// <summary>
		/// setup the given control's WritingSystem[Factory] and Stylesheet related functionality
		/// </summary>
		/// <param name="control"></param>
		/// <param name="cache"></param>
		/// <param name="mediator">used to get stylesheet</param>
		/// <param name="wsDefault">used to set WritingSytemCode and Font for the control</param>
		public static void SetupWritingSystemAndStylesheetInfo(IWritingSystemAndStylesheet control,
			FdoCache cache, Mediator mediator, int wsDefault)
		{
			control.WritingSystemFactory = cache.WritingSystemFactory;
			control.WritingSystemCode = wsDefault;
			control.Font = new System.Drawing.Font(cache.ServiceLocator.WritingSystemManager.Get(wsDefault).DefaultFontName, 10);
			control.StyleSheet = FontHeightAdjuster.StyleSheetFromMediator(mediator);
		}
Exemplo n.º 3
0
 /// <summary>
 /// setup the given control's WritingSystem[Factory] and Stylesheet related functionality
 /// </summary>
 /// <param name="control"></param>
 /// <param name="cache"></param>
 /// <param name="mediator">used to get stylesheet</param>
 /// <param name="wsDefault">used to set WritingSytemCode and Font for the control</param>
 public static void SetupWritingSystemAndStylesheetInfo(IWritingSystemAndStylesheet control,
                                                        FdoCache cache, Mediator mediator, int wsDefault)
 {
     control.WritingSystemFactory = cache.LanguageWritingSystemFactoryAccessor;
     control.WritingSystemCode    = wsDefault;
     control.Font       = new System.Drawing.Font(cache.LangProject.GetDefaultFontForWs(wsDefault), 10);
     control.StyleSheet = FontHeightAdjuster.StyleSheetFromMediator(mediator);
 }
 /// <summary>
 /// setup the given control's WritingSystem[Factory] and Stylesheet related functionality
 /// </summary>
 /// <param name="control"></param>
 /// <param name="cache"></param>
 /// <param name="mediator">used to get stylesheet</param>
 /// <param name="wsDefault">used to set WritingSytemCode and Font for the control</param>
 public static void SetupWritingSystemAndStylesheetInfo(IWritingSystemAndStylesheet control,
                                                        FdoCache cache, Mediator mediator, int wsDefault)
 {
     control.WritingSystemFactory = cache.WritingSystemFactory;
     control.WritingSystemCode    = wsDefault;
     control.Font       = new System.Drawing.Font(cache.ServiceLocator.WritingSystemManager.Get(wsDefault).DefaultFontName, 10);
     control.StyleSheet = FontHeightAdjuster.StyleSheetFromMediator(mediator);
 }
Exemplo n.º 5
0
 /// <summary>
 /// setup the given control's WritingSystem[Factory] and Stylesheet related functionality
 /// </summary>
 /// <param name="propertyTable"></param>
 /// <param name="control"></param>
 /// <param name="cache"></param>
 /// <param name="wsDefault">used to set WritingSytemCode and Font for the control</param>
 public static void SetupWritingSystemAndStylesheetInfo(PropertyTable propertyTable, IWritingSystemAndStylesheet control,
                                                        LcmCache cache, int wsDefault)
 {
     control.WritingSystemFactory = cache.WritingSystemFactory;
     control.WritingSystemCode    = wsDefault;
     control.Font       = new System.Drawing.Font(cache.ServiceLocator.WritingSystemManager.Get(wsDefault).DefaultFontName, 10);
     control.StyleSheet = FontHeightAdjuster.StyleSheetFromPropertyTable(propertyTable);
 }