Used to represent a list of fonts.
コード例 #1
0
 /// <summary>
 /// Adds the given <see cref="FontSet"/> to the group.
 /// </summary>
 /// <remarks>
 /// This replaces any previous <see cref="FontSet"/> with the same name.
 /// </remarks>
 /// <param name="p_strName">The name of the <see cref="FontSet"/>.</param>
 /// <param name="p_fstSet">The <see cref="FontSet"/>.</param>
 public void AddFontSet(string p_strName, FontSet p_fstSet)
 {
     m_dicFontSets[p_strName] = p_fstSet;
 }
コード例 #2
0
 /// <summary>
 /// A simple constructor that initializes the object with the given values.
 /// </summary>
 /// <param name="p_fstDefault">The default <see cref="FontSet"/> for the group.</param>
 public FontSetGroup(FontSet p_fstDefault)
 {
     DefaultFontSet = p_fstDefault;
 }
コード例 #3
0
		/// <summary>
		/// A simple constructor that initializes the object with the given values.
		/// </summary>
		/// <param name="p_fstDefault">The default <see cref="FontSet"/> for the group.</param>
		public FontSetGroup(FontSet p_fstDefault)
		{
			DefaultFontSet = p_fstDefault;
		}
コード例 #4
0
		/// <summary>
		/// Adds the given <see cref="FontSet"/> to the group.
		/// </summary>
		/// <remarks>
		/// This replaces any previous <see cref="FontSet"/> with the same name.
		/// </remarks>
		/// <param name="p_strName">The name of the <see cref="FontSet"/>.</param>
		/// <param name="p_fstSet">The <see cref="FontSet"/>.</param>
		public void AddFontSet(string p_strName, FontSet p_fstSet)
		{
			m_dicFontSets[p_strName] = p_fstSet;
		}
コード例 #5
0
		/// <summary>
		/// Sets up the fonts.
		/// </summary>
		/// <returns>The <see cref="NexusFontSetResolver"/> to be used.</returns>
		private NexusFontSetResolver SetUpFonts()
		{
			FontManager.Add("LinBiolinum", Resources.LinBiolinum_RB);
			FontManager.Add("LinBiolinum", Resources.LinBiolinum_RI);

			FontSet fstDefault = new FontSet(new string[] { "Microsoft Sans Serif", "Arial" });
			FontSetGroup fsgDefault = new FontSetGroup(fstDefault);
			fsgDefault.AddFontSet("StandardText", fstDefault);
			fsgDefault.AddFontSet("HeadingText", fstDefault);
			fsgDefault.AddFontSet("SmallText", new FontSet(new string[] { "Segoe UI", "Arial" }));
			fsgDefault.AddFontSet("MenuText", new FontSet(new string[] { "Segoe UI", "Arial" }));
			fsgDefault.AddFontSet("GameSearchText", new FontSet(new string[] { "LinBiolinum" }));
			fsgDefault.AddFontSet("TestText", new FontSet(new string[] { "Wingdings" }));

			NexusFontSetResolver fsrResolver = new NexusFontSetResolver();
			fsrResolver.AddFontSets(fsgDefault);

			FontProvider.SetFontSetResolver(fsrResolver);
			return fsrResolver;
		}