Пример #1
0
		/// --------------------------------------------------------------------------------
		/// <summary>
		///
		/// </summary>
		/// <param name="fdoCache"></param>
		/// <param name="alIDs"></param>
		/// <returns></returns>
		/// --------------------------------------------------------------------------------
		public static LgWritingSystemCollection Load(FdoCache fdoCache, Set<int> alIDs)
		{
			LgWritingSystemCollection lec = new LgWritingSystemCollection(fdoCache);
			foreach (int hvo in alIDs)
				lec.Add(new LgWritingSystem(fdoCache, hvo));
			return lec;
		}
Пример #2
0
		/// ------------------------------------------------------------------------------------
		/// <summary>
		/// Add the writing systems to the collection in the cache.
		/// </summary>
		/// ------------------------------------------------------------------------------------
		public void InitializeWritingSystemEncodings()
		{
			CheckDisposed();
			FdoCache fdoCache = Cache;
			LgWritingSystemCollection wsCollection = new LgWritingSystemCollection(fdoCache);

			// HVO  | ICU Locale | English Name | Spanish Name | French Name | IPA Name |
			// -----+------------+--------------+--------------+-------------+-----------
			// 1001 | en         | English      | inglés       |             |          |
			// 2346 | es         | Spanish      | español      | espagnol    | español  |
			// 4568 | fr         |              | francés      | francais    |          |
			// 2398 | en-ipa     | English IPA  |              |             | aipie    |
			// ???? | de         | German       |              |             | Deutsch  |
			// ???? | xkal       | Kalaba       |              |             |          |
			// ???? | ur         | Urdu         |              |             |          |

			wsCollection.Add(CreateWritingSystem(fdoCache, s_wsHvos.En,
				"en", new int[] { s_wsHvos.En, s_wsHvos.Es }, new string[] { "English", "inglés" },
				"Arial", "Times New Roman", "Charis SIL"));
			wsCollection.Add(CreateWritingSystem(fdoCache, s_wsHvos.Es,
				"es", new int[] { s_wsHvos.En, s_wsHvos.Es, s_wsHvos.Fr, s_wsHvos.Ipa },
				new string[] { "Spanish", "español", "espagnol", "español" },
				"Arial", "Times New Roman", "Charis SIL"));
			wsCollection.Add(CreateWritingSystem(fdoCache, s_wsHvos.Fr,
				"fr", new int[] { s_wsHvos.Es, s_wsHvos.Fr }, new string[] { "francés", "francais" },
				"Arial", "Times New Roman", "Charis SIL"));
			wsCollection.Add(CreateWritingSystem(fdoCache, s_wsHvos.Ipa,
				"en-IPA", new int[] { s_wsHvos.En, s_wsHvos.Ipa }, new string[] { "English IPA", "aipie" },
				null, "SILDoulos IPA93", "Charis SIL"));
			wsCollection.Add(CreateWritingSystem(fdoCache, s_wsHvos.De,
				"de", new int[] { s_wsHvos.En, s_wsHvos.Ipa }, new string[] { "German", "Deutsch" },
				"Arial", "Times New Roman", "Charis SIL"));
			wsCollection.Add(CreateWritingSystem(fdoCache, s_wsHvos.XKal,
				"xkal", new int[] { s_wsHvos.En }, new string[] { "Kalaba" },
				"Arial", "Times New Roman", "Charis SIL"));
			wsCollection.Add(CreateWritingSystem(fdoCache, s_wsHvos.Ur,
				"ur", new int[] { s_wsHvos.En }, new string[] { "Urdu" },
				"Arial Unicode MS", null, "Charis SIL"));

			((NewFdoCache)m_fdoCache).SetLanguageEncodings(wsCollection);
		}