• 大小: 0.05M
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2024-05-02
  • 语言: C#
  • 标签: winform  vs2013  FORM  2013  ORM  

资源简介

输入框自动切换中文(C#,winform),vs2013

资源截图

代码片段和文件信息

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;

namespace demo
{
    public partial class Form1 : Form
    {
        public Form1()
        {
            InitializeComponent();
        }

        private void ultraFormattedTextEditorDesc_MouseDown(object sender MouseEventArgs e)
        {
            ultraFormattedTextEditorDesc.ImeMode = System.Windows.Forms.ImeMode.On;
            //InputLanguage.CurrentInputLanguage=InputLanguage.FromCulture(System.Globalization.CultureInfo.GetCultureInfo(“zh-CN“));

            string[] languagename = new string[] { “五笔“ “拼音“ “中文“ };
            bool bResult = false;
            for (int i = 0; i < languagename.Length; i++)
            {
                foreach (InputLanguage lang in InputLanguage.InstalledInputLanguages)
                {
                    if (lang.LayoutName.IndexOf(languagename[i]) >= 0)
                    {
                        InputLanguage.CurrentInputLanguage = lang;
                        bResult = true;
                        break;
                    }
                }

                if (bResult)
                    break;
            }

        }

        private void richTextBox1_MouseDown(object sender MouseEventArgs e)
        {
            richTextBox1.ImeMode = System.Windows.Forms.ImeMode.On;
            //InputLanguage.CurrentInputLanguage=InputLanguage.FromCulture(System.Globalization.CultureInfo.GetCultureInfo(“zh-CN“));

            string[] languagename = new string[] { “美式键盘“ };
            bool bResult = false;
            for (int i = 0; i < languagename.Length; i++)
            {
                foreach (InputLanguage lang in InputLanguage.InstalledInputLanguages)
                {
                    if (lang.LayoutName.IndexOf(languagename[i]) >= 0)
                    {
                        InputLanguage.CurrentInputLanguage = lang;
                        bResult = true;
                        break;
                    }
                }

                if (bResult)
                    break;
            }
        }
    }
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件        187  2020-08-06 10:14  demo\demo\App.config

     文件       9728  2020-08-06 10:25  demo\demo\bin\Debug\demo.exe

     文件        187  2020-08-06 10:14  demo\demo\bin\Debug\demo.exe.config

     文件      26112  2020-08-06 10:25  demo\demo\bin\Debug\demo.pdb

     文件      24224  2020-08-06 10:25  demo\demo\bin\Debug\demo.vshost.exe

     文件        187  2020-08-06 10:14  demo\demo\bin\Debug\demo.vshost.exe.config

     文件        490  2019-03-19 12:46  demo\demo\bin\Debug\demo.vshost.exe.manifest

     文件       3788  2020-08-06 10:22  demo\demo\demo.csproj

     文件       2325  2020-08-06 10:25  demo\demo\Form1.cs

     文件       3661  2020-08-06 10:23  demo\demo\Form1.Designer.cs

     文件       5817  2020-08-06 10:23  demo\demo\Form1.resx

     文件        690  2020-08-06 10:25  demo\demo\obj\Debug\demo.csproj.FileListAbsolute.txt

     文件        977  2020-08-06 10:24  demo\demo\obj\Debug\demo.csproj.GenerateResource.Cache

     文件       2211  2020-08-06 10:22  demo\demo\obj\Debug\demo.csprojResolveAssemblyReference.cache

     文件       9728  2020-08-06 10:25  demo\demo\obj\Debug\demo.exe

     文件        180  2020-08-06 10:24  demo\demo\obj\Debug\demo.Form1.resources

     文件      26112  2020-08-06 10:25  demo\demo\obj\Debug\demo.pdb

     文件        180  2020-08-06 10:22  demo\demo\obj\Debug\demo.Properties.Resources.resources

     文件        865  2020-08-06 10:14  demo\demo\obj\Debug\DesignTimeResolveAssemblyReferences.cache

     文件       6983  2020-08-06 10:14  demo\demo\obj\Debug\DesignTimeResolveAssemblyReferencesInput.cache

     文件          0  2020-08-06 10:14  demo\demo\obj\Debug\TemporaryGeneratedFile_036C0B5B-1481-4323-8D20-8F5ADCB23D92.cs

     文件          0  2020-08-06 10:14  demo\demo\obj\Debug\TemporaryGeneratedFile_5937a670-0e60-4077-877b-f7221da3dda1.cs

     文件          0  2020-08-06 10:14  demo\demo\obj\Debug\TemporaryGeneratedFile_E7A71F73-0F8D-4B9B-B56E-8E70B10BC5D3.cs

     文件        516  2020-08-06 10:14  demo\demo\Program.cs

     文件       1332  2020-08-06 10:14  demo\demo\Properties\AssemblyInfo.cs

     文件       2860  2020-08-06 10:14  demo\demo\Properties\Resources.Designer.cs

     文件       5612  2020-08-06 10:14  demo\demo\Properties\Resources.resx

     文件       1091  2020-08-06 10:14  demo\demo\Properties\Settings.Designer.cs

     文件        249  2020-08-06 10:14  demo\demo\Properties\Settings.settings

     文件        981  2020-08-06 10:14  demo\demo.sln

............此处省略12个文件信息

评论

共有 条评论