├── .gitignore
├── Merge files in one.sln
├── Merge files in one.suo
├── Merge files in one
├── DllExport
│ ├── DllExportAttribute.cs
│ ├── Mono.Cecil.dll
│ ├── NppPlugin.DllExport.MSBuild.dll
│ ├── NppPlugin.DllExport.dll
│ └── NppPlugin.DllExport.targets
├── Forms
│ ├── frmMyDlg.Designer.cs
│ ├── frmMyDlg.cs
│ └── frmMyDlg.resx
├── Main.cs
├── Merge files in one.csproj
├── Merge files in one.csproj.user
├── Merge files in one.v11.suo
├── NppPluginNETBase.cs
├── NppPluginNETHelper.cs
├── Properties
│ ├── AssemblyInfo.cs
│ ├── Resources.Designer.cs
│ ├── Resources.resx
│ ├── star.png
│ └── star_bmp.bmp
├── Resources
│ └── Thumbs.db
├── UnmanagedExports.cs
└── obj
│ ├── Debug
│ └── TempPE
│ │ └── Properties.Resources.Designer.cs.dll
│ └── Release
│ └── TempPE
│ └── Properties.Resources.Designer.cs.dll
└── appveyor.yml
/.gitignore:
--------------------------------------------------------------------------------
1 | #-------------------------------------------------------------------------------
2 | # VisualStudio
3 |
4 | #-- User-specific files
5 | *.suo
6 | *.user
7 | *.sln.docstates
8 |
9 | #-- Build results
10 | [Dd]ebug/
11 | [Rr]elease/
12 | x64/
13 | x86/
14 | #[Bb]in/
15 | [Oo]bj/
16 | *.pdb
17 |
18 | #-- Visual C++ cache files
19 | .vs/
20 | ipch/
21 | *.aps
22 | *.ncb
23 | *.opensdf
24 | *.sdf
25 | *.cachefile
26 |
27 | #-- Backup & report files from converting an old project file to a newer
28 | # Visual Studio version. Backup files are not needed, because we have git ;-)
29 | _UpgradeReport_Files/
30 | Backup*/
31 | UpgradeLog*.XML
32 | UpgradeLog*.htm
33 |
34 | #-- Others
35 | *_i.c
36 | *_p.c
37 | *.ilk
38 | *.meta
39 | *.obj
40 | *.pch
41 | #*.pdb
42 | *.pgc
43 | *.pgd
44 | *.rsp
45 | *.sbr
46 | *.tlb
47 | *.tli
48 | *.tlh
49 | *.tmp
50 | *.tmp_proj
51 | *.log
52 | .builds
53 | *.pidb
54 |
55 |
--------------------------------------------------------------------------------
/Merge files in one.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio 2012
4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Merge files in one", "Merge files in one\Merge files in one.csproj", "{5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}"
5 | EndProject
6 | Global
7 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
8 | Debug|x64 = Debug|x64
9 | Debug|x86 = Debug|x86
10 | Release|x64 = Release|x64
11 | Release|x86 = Release|x86
12 | EndGlobalSection
13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
14 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}.Debug|x64.ActiveCfg = Debug|x64
15 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}.Debug|x64.Build.0 = Debug|x64
16 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}.Debug|x86.ActiveCfg = Debug|x86
17 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}.Debug|x86.Build.0 = Debug|x86
18 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}.Release|x64.ActiveCfg = Release|x64
19 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}.Release|x64.Build.0 = Release|x64
20 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}.Release|x86.ActiveCfg = Release|x86
21 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}.Release|x86.Build.0 = Release|x86
22 | EndGlobalSection
23 | GlobalSection(SolutionProperties) = preSolution
24 | HideSolutionNode = FALSE
25 | EndGlobalSection
26 | EndGlobal
27 |
--------------------------------------------------------------------------------
/Merge files in one.suo:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one.suo
--------------------------------------------------------------------------------
/Merge files in one/DllExport/DllExportAttribute.cs:
--------------------------------------------------------------------------------
1 | // NPP plugin platform for .Net v0.93.96 by Kasper B. Graversen etc.
2 | using System;
3 | using System.Runtime.InteropServices;
4 |
5 | namespace NppPlugin.DllExport
6 | {
7 | [AttributeUsage(AttributeTargets.Method, AllowMultiple = false)]
8 | partial class DllExportAttribute : Attribute
9 | {
10 | public DllExportAttribute()
11 | {
12 | }
13 |
14 | public DllExportAttribute(string exportName)
15 | : this(exportName, CallingConvention.StdCall)
16 | {
17 | }
18 |
19 | public DllExportAttribute(string exportName, CallingConvention callingConvention)
20 | {
21 | ExportName = exportName;
22 | CallingConvention = callingConvention;
23 | }
24 |
25 | public CallingConvention CallingConvention { get; set; }
26 |
27 | public string ExportName { get; set; }
28 | }
29 | }
--------------------------------------------------------------------------------
/Merge files in one/DllExport/Mono.Cecil.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/DllExport/Mono.Cecil.dll
--------------------------------------------------------------------------------
/Merge files in one/DllExport/NppPlugin.DllExport.MSBuild.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/DllExport/NppPlugin.DllExport.MSBuild.dll
--------------------------------------------------------------------------------
/Merge files in one/DllExport/NppPlugin.DllExport.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/DllExport/NppPlugin.DllExport.dll
--------------------------------------------------------------------------------
/Merge files in one/DllExport/NppPlugin.DllExport.targets:
--------------------------------------------------------------------------------
1 |
3 |
5 |
8 |
22 |
23 |
--------------------------------------------------------------------------------
/Merge files in one/Forms/frmMyDlg.Designer.cs:
--------------------------------------------------------------------------------
1 | namespace Merge_files_in_one
2 | {
3 | partial class frmMyDlg
4 | {
5 | ///
6 | /// Required designer variable.
7 | ///
8 | private System.ComponentModel.IContainer components = null;
9 |
10 | ///
11 | /// Clean up any resources being used.
12 | ///
13 | /// true if managed resources should be disposed; otherwise, false.
14 | protected override void Dispose(bool disposing)
15 | {
16 | if (disposing && (components != null))
17 | {
18 | components.Dispose();
19 | }
20 | base.Dispose(disposing);
21 | }
22 |
23 | #region Windows Form Designer generated code
24 |
25 | ///
26 | /// Required method for Designer support - do not modify
27 | /// the contents of this method with the code editor.
28 | ///
29 | private void InitializeComponent()
30 | {
31 | this.tabControl1 = new System.Windows.Forms.TabControl();
32 | this.tabPage1 = new System.Windows.Forms.TabPage();
33 | this.checkBox1 = new System.Windows.Forms.CheckBox();
34 | this.textBox2 = new System.Windows.Forms.TextBox();
35 | this.textBox3 = new System.Windows.Forms.TextBox();
36 | this.textBox1 = new System.Windows.Forms.TextBox();
37 | this.label3 = new System.Windows.Forms.Label();
38 | this.button1 = new System.Windows.Forms.Button();
39 | this.label1 = new System.Windows.Forms.Label();
40 | this.label2 = new System.Windows.Forms.Label();
41 | this.tabControl1.SuspendLayout();
42 | this.tabPage1.SuspendLayout();
43 | this.SuspendLayout();
44 | //
45 | // tabControl1
46 | //
47 | this.tabControl1.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
48 | | System.Windows.Forms.AnchorStyles.Left)
49 | | System.Windows.Forms.AnchorStyles.Right)));
50 | this.tabControl1.Controls.Add(this.tabPage1);
51 | this.tabControl1.Location = new System.Drawing.Point(3, 65);
52 | this.tabControl1.Name = "tabControl1";
53 | this.tabControl1.SelectedIndex = 0;
54 | this.tabControl1.Size = new System.Drawing.Size(399, 178);
55 | this.tabControl1.TabIndex = 0;
56 | //
57 | // tabPage1
58 | //
59 | this.tabPage1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192)))));
60 | this.tabPage1.Controls.Add(this.checkBox1);
61 | this.tabPage1.Controls.Add(this.textBox2);
62 | this.tabPage1.Controls.Add(this.textBox3);
63 | this.tabPage1.Controls.Add(this.textBox1);
64 | this.tabPage1.Controls.Add(this.label3);
65 | this.tabPage1.Controls.Add(this.button1);
66 | this.tabPage1.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
67 | this.tabPage1.Location = new System.Drawing.Point(4, 22);
68 | this.tabPage1.Name = "tabPage1";
69 | this.tabPage1.Padding = new System.Windows.Forms.Padding(3);
70 | this.tabPage1.Size = new System.Drawing.Size(391, 152);
71 | this.tabPage1.TabIndex = 0;
72 | //
73 | // checkBox1
74 | //
75 | this.checkBox1.AutoSize = true;
76 | this.checkBox1.Location = new System.Drawing.Point(244, 81);
77 | this.checkBox1.Name = "checkBox1";
78 | this.checkBox1.RightToLeft = System.Windows.Forms.RightToLeft.Yes;
79 | this.checkBox1.Size = new System.Drawing.Size(120, 20);
80 | this.checkBox1.TabIndex = 3;
81 | this.checkBox1.Text = "Vorbose Output";
82 | this.checkBox1.UseVisualStyleBackColor = true;
83 | //
84 | // textBox2
85 | //
86 | this.textBox2.Location = new System.Drawing.Point(6, 116);
87 | this.textBox2.MaxLength = 2147483647;
88 | this.textBox2.Multiline = true;
89 | this.textBox2.Name = "textBox2";
90 | this.textBox2.Size = new System.Drawing.Size(100, 20);
91 | this.textBox2.TabIndex = 4;
92 | this.textBox2.Visible = false;
93 | this.textBox2.WordWrap = false;
94 | //
95 | // textBox3
96 | //
97 | this.textBox3.Location = new System.Drawing.Point(83, 116);
98 | this.textBox3.MaxLength = 2147483647;
99 | this.textBox3.Multiline = true;
100 | this.textBox3.Name = "textBox3";
101 | this.textBox3.Size = new System.Drawing.Size(100, 20);
102 | this.textBox3.TabIndex = 3;
103 | this.textBox3.Visible = false;
104 | //
105 | // textBox1
106 | //
107 | this.textBox1.Location = new System.Drawing.Point(63, 101);
108 | this.textBox1.MaxLength = 2147483647;
109 | this.textBox1.Multiline = true;
110 | this.textBox1.Name = "textBox1";
111 | this.textBox1.Size = new System.Drawing.Size(100, 20);
112 | this.textBox1.TabIndex = 1;
113 | this.textBox1.Visible = false;
114 | //
115 | // label3
116 | //
117 | this.label3.AutoSize = true;
118 | this.label3.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
119 | this.label3.Location = new System.Drawing.Point(47, 14);
120 | this.label3.Name = "label3";
121 | this.label3.Size = new System.Drawing.Size(45, 16);
122 | this.label3.TabIndex = 2;
123 | this.label3.Text = "label3";
124 | //
125 | // button1
126 | //
127 | this.button1.Location = new System.Drawing.Point(244, 116);
128 | this.button1.Name = "button1";
129 | this.button1.Size = new System.Drawing.Size(142, 28);
130 | this.button1.TabIndex = 0;
131 | this.button1.Text = "Merge files in one";
132 | this.button1.UseVisualStyleBackColor = true;
133 | this.button1.Visible = false;
134 | this.button1.Click += new System.EventHandler(this.button1_Click);
135 | //
136 | // label1
137 | //
138 | this.label1.AutoSize = true;
139 | this.label1.Location = new System.Drawing.Point(35, 9);
140 | this.label1.Name = "label1";
141 | this.label1.Size = new System.Drawing.Size(0, 13);
142 | this.label1.TabIndex = 1;
143 | //
144 | // label2
145 | //
146 | this.label2.AutoSize = true;
147 | this.label2.Location = new System.Drawing.Point(35, 38);
148 | this.label2.Name = "label2";
149 | this.label2.Size = new System.Drawing.Size(0, 13);
150 | this.label2.TabIndex = 2;
151 | //
152 | // frmMyDlg
153 | //
154 | this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
155 | this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
156 | this.ClientSize = new System.Drawing.Size(401, 245);
157 | this.Controls.Add(this.label2);
158 | this.Controls.Add(this.label1);
159 | this.Controls.Add(this.tabControl1);
160 | this.MaximizeBox = false;
161 | this.MinimizeBox = false;
162 | this.Name = "frmMyDlg";
163 | this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
164 | this.Text = "Merge files in one";
165 | this.TopMost = true;
166 | this.TransparencyKey = System.Drawing.Color.White;
167 | this.Activated += new System.EventHandler(this.Form_Activated);
168 | this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.form_closing);
169 | this.tabControl1.ResumeLayout(false);
170 | this.tabPage1.ResumeLayout(false);
171 | this.tabPage1.PerformLayout();
172 | this.ResumeLayout(false);
173 | this.PerformLayout();
174 |
175 | }
176 |
177 | #endregion
178 |
179 | private System.Windows.Forms.TabControl tabControl1;
180 | private System.Windows.Forms.TabPage tabPage1;
181 | private System.Windows.Forms.Button button1;
182 | private System.Windows.Forms.Label label1;
183 | private System.Windows.Forms.Label label2;
184 | private System.Windows.Forms.TextBox textBox1;
185 | private System.Windows.Forms.Label label3;
186 | private System.Windows.Forms.CheckBox checkBox1;
187 | private System.Windows.Forms.TextBox textBox3;
188 | private System.Windows.Forms.TextBox textBox2;
189 |
190 | }
191 | }
--------------------------------------------------------------------------------
/Merge files in one/Forms/frmMyDlg.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.IO;
3 | using System.Collections.Generic;
4 | using System.ComponentModel;
5 | using System.Drawing;
6 | using System.Text;
7 | using System.Windows.Forms;
8 | using NppPluginNET;
9 | using System.Diagnostics;
10 | using System.Text.RegularExpressions;
11 |
12 | namespace Merge_files_in_one
13 | {
14 | public partial class frmMyDlg : Form
15 | {
16 | public static string outputString;
17 | internal const string PluginName = "Merge files in one";
18 | static string iniFilePath = null;
19 | static bool someSetting = false;
20 |
21 | public frmMyDlg()
22 | {
23 | InitializeComponent();
24 |
25 | StringBuilder sbIniFilePathkk = new StringBuilder(Win32.MAX_PATH);
26 | Win32.SendMessage(PluginBase.nppData._nppHandle, NppMsg.NPPM_GETPLUGINSCONFIGDIR, Win32.MAX_PATH, sbIniFilePathkk);
27 | iniFilePath = sbIniFilePathkk.ToString();
28 | if (!Directory.Exists(iniFilePath)) Directory.CreateDirectory(iniFilePath);
29 | iniFilePath = Path.Combine(iniFilePath, PluginName + ".ini");
30 |
31 |
32 | StringBuilder filename = new StringBuilder(Win32.MAX_PATH);
33 | Win32.SendMessage(PluginBase.nppData._nppHandle, NppMsg.NPPM_GETFILENAME, 0, filename);
34 |
35 | label1.Text = filename.ToString();
36 |
37 | textBox1.Text = GetCurrentDocumentText();
38 | Win32.WritePrivateProfileString(PluginName, "NPPN_BUFFERACTIVATED_N", "True", iniFilePath);
39 | Win32.WritePrivateProfileString(PluginName, "filename", filename.ToString(), iniFilePath);
40 |
41 | }
42 |
43 | private void button1_Click(object sender, EventArgs e)
44 | {
45 | try
46 | {
47 | var countm = textBox1.Lines.Length;
48 | var countnn = textBox2.Lines.Length;
49 | if (countm > countnn)
50 | {
51 | for (int i = 0; i < countnn; i++)
52 | {
53 | textBox1.AppendText(Environment.NewLine);
54 | }
55 | }
56 | else
57 | {
58 | for (int i = 0; i < countnn; i++)
59 | {
60 | // MessageBox.Show(i.ToString());
61 | textBox1.AppendText(Environment.NewLine);
62 | }
63 | // MessageBox.Show(textBox1.Lines.Length.ToString() + "yyyy" + textBox1.Lines.Length.ToString());
64 | }
65 | var count = textBox1.Lines.Length;
66 | var countn = textBox2.Lines.Length;
67 | var kmj = textBox1.Lines.Length;
68 | if ((count > countn) || (count == countn)) {kmj = countn;} else {kmj = count;};
69 | int x = -1;
70 | string linex;
71 | string[] lines = textBox1.Lines;
72 | string[] line = textBox2.Lines;
73 | for (int i = 0; i < kmj; i++)
74 | {
75 | x += 1;
76 | if (checkBox1.Checked == true)
77 | {
78 | linex = Regex.Replace(line[x], "$", " 3f5456cfsd661lld33dGuid9CA0F324 " + lines[x]);
79 | lines[x] = linex;
80 | textBox3.Lines = lines;
81 | }
82 | else
83 | {
84 | linex = Regex.Replace(lines[x], "$", " 3f5456cfsd661lld33dGuid9CA0F324 " + line[x]);
85 | lines[x] = linex;
86 | textBox3.Lines = lines;
87 | }
88 | }
89 | outputString = textBox3.Text;
90 | textBox3.Clear();
91 | if (string.IsNullOrEmpty(outputString)) return;
92 | Win32.SendMessage(PluginBase.nppData._nppHandle, NppMsg.NPPM_MENUCOMMAND, 0, NppMenuCmd.IDM_FILE_NEW);
93 |
94 | Win32.SendMessage(PluginBase.GetCurrentScintilla(), SciMsg.SCI_SETTEXT, 0, outputString.TrimEnd());
95 | }
96 | catch (Exception exp)
97 | {
98 | MessageBox.Show("Error. " + exp.Message);
99 | }
100 | }
101 |
102 | private void button2_Click(object sender, EventArgs e)
103 | {
104 |
105 | }
106 |
107 | public static void NPPN_BUFFERACTIVATED_N()
108 | {
109 | someSetting = (Win32.GetPrivateProfileInt(PluginName, "nppn_bufferactivated_n", 0, iniFilePath) != 0);
110 | if (someSetting.ToString() == "False")
111 | {
112 | return;
113 | }
114 | StringBuilder cur_filename = new StringBuilder(Win32.MAX_PATH);
115 | StringBuilder sbTempm = new StringBuilder(Win32.MAX_PATH);
116 | Win32.GetPrivateProfileString(PluginName, "filename", "", sbTempm, Win32.MAX_PATH, iniFilePath);
117 | Win32.SendMessage(PluginBase.nppData._nppHandle, NppMsg.NPPM_GETFILENAME, 0, cur_filename);
118 | if (cur_filename.ToString() == sbTempm.ToString())
119 | {
120 | return;
121 | }
122 | else
123 | {
124 | Win32.WritePrivateProfileString(PluginName, "filename", cur_filename.ToString(), iniFilePath);
125 | }
126 | }
127 | private string GetCurrentDocumentText()
128 | {
129 | IntPtr curScintilla = PluginBase.GetCurrentScintilla();
130 | return GetDocumentText(curScintilla);
131 | }
132 |
133 | private string GetDocumentText(IntPtr curScintilla)
134 | {
135 | int length = (int)Win32.SendMessage(curScintilla, SciMsg.SCI_GETLENGTH, 0, 0) + 1;
136 | StringBuilder sb = new StringBuilder(length);
137 | Win32.SendMessage(curScintilla, SciMsg.SCI_GETTEXT, length, sb);
138 | return sb.ToString();
139 | }
140 |
141 | private void Form_Activated(object sender, EventArgs e)
142 | {
143 | StringBuilder sbTemp = new StringBuilder(Win32.MAX_PATH);
144 | StringBuilder cur_filenamen = new StringBuilder(Win32.MAX_PATH);
145 |
146 | Win32.SendMessage(PluginBase.nppData._nppHandle, NppMsg.NPPM_GETFILENAME, 0, cur_filenamen);
147 |
148 | Win32.GetPrivateProfileString(PluginName, "filename", "", sbTemp, Win32.MAX_PATH, iniFilePath);
149 | if (sbTemp.ToString() == cur_filenamen.ToString())
150 | {
151 | label3.Text = sbTemp.ToString() + " is selected \n swicth to second file now";
152 | return;
153 | }
154 | else
155 | {
156 | label3.Visible = false;
157 | button1.Visible = true;
158 | label2.Text = cur_filenamen.ToString();
159 | textBox2.Text = GetCurrentDocumentText();
160 |
161 | }
162 |
163 | }
164 |
165 | private void form_closing(object sender, FormClosingEventArgs e)
166 | {
167 |
168 | Win32.WritePrivateProfileString(PluginName, "nppn_bufferactivated_n", "False", iniFilePath);
169 |
170 | }
171 | }
172 | }
173 |
--------------------------------------------------------------------------------
/Merge files in one/Forms/frmMyDlg.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 | text/microsoft-resx
110 |
111 |
112 | 2.0
113 |
114 |
115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
119 |
120 |
--------------------------------------------------------------------------------
/Merge files in one/Main.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.IO;
3 | using System.Text;
4 | using System.Linq;
5 | using System.Windows.Forms;
6 | using System.Text.RegularExpressions;
7 | using NppPluginNET;
8 |
9 | namespace Merge_files_in_one
10 | {
11 | class Main
12 | {
13 | #region " Fields "
14 | internal const string PluginName = "Merge files in one";
15 | static string iniFilePath = null;
16 | static frmMyDlg frmMyDlg = null;
17 | static bool someSetting = false;
18 | #endregion
19 |
20 | #region " StartUp/CleanUp "
21 | internal static void CommandMenuInit()
22 | {
23 | StringBuilder sbIniFilePath = new StringBuilder(Win32.MAX_PATH);
24 | Win32.SendMessage(PluginBase.nppData._nppHandle, NppMsg.NPPM_GETPLUGINSCONFIGDIR, Win32.MAX_PATH, sbIniFilePath);
25 | iniFilePath = sbIniFilePath.ToString();
26 | if (!Directory.Exists(iniFilePath)) Directory.CreateDirectory(iniFilePath);
27 | iniFilePath = Path.Combine(iniFilePath, PluginName + ".ini");
28 |
29 | PluginBase.SetCommand(0, "Merge files in one", all_file_text, new ShortcutKey(false, false, false, Keys.None));
30 | PluginBase.SetCommand(3, "About", about, new ShortcutKey(false, false, false, Keys.None));
31 | }
32 | internal static void SetToolBarIcon()
33 | {
34 |
35 | }
36 |
37 | internal static void PluginCleanUp()
38 | {
39 | Win32.WritePrivateProfileString("SomeSection", "SomeKey", someSetting ? "1" : "0", iniFilePath);
40 | }
41 | #endregion
42 |
43 | #region " Menu functions "
44 | internal static void about()
45 | {
46 | var ss = "\n ****** Merge files in one ****** \n build by G. Singh \n 03-11-2019 build 1.2.0.0 ";
47 | MessageBox.Show(ss);
48 | }
49 | internal static void all_file_text()
50 | {
51 | frmMyDlg = new frmMyDlg();
52 | frmMyDlg.Show();
53 | frmMyDlg = null;
54 | }
55 | #endregion
56 | }
57 | }
--------------------------------------------------------------------------------
/Merge files in one/Merge files in one.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Debug
5 | x86
6 | 2.0
7 | {5E85A5DB-FB70-405B-85FB-24A6A4AA3DFB}
8 | Library
9 | Properties
10 | Merge_files_in_one
11 | Merge files in one
12 | bin\Debug\
13 | v3.5
14 |
15 |
16 | 3.5
17 |
18 | publish\
19 | true
20 | Disk
21 | false
22 | Foreground
23 | 7
24 | Days
25 | false
26 | false
27 | true
28 | 0
29 | 1.0.0.%2a
30 | false
31 | false
32 | true
33 |
34 |
35 |
36 |
37 | true
38 | bin\x64\Debug\
39 | DEBUG;TRACE
40 | full
41 | x64
42 | prompt
43 | MinimumRecommendedRules.ruleset
44 |
45 |
46 | bin\x64\Release\
47 | TRACE
48 | true
49 | pdbonly
50 | x64
51 | prompt
52 | MinimumRecommendedRules.ruleset
53 |
54 |
55 | true
56 | bin\x86\Debug\
57 | DEBUG;TRACE
58 | full
59 | x86
60 | prompt
61 | MinimumRecommendedRules.ruleset
62 |
63 |
64 | bin\x86\Release\
65 | TRACE
66 | true
67 | pdbonly
68 | x86
69 | prompt
70 | MinimumRecommendedRules.ruleset
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 | Form
81 |
82 |
83 | frmMyDlg.cs
84 |
85 |
86 |
87 |
88 |
89 |
90 | True
91 | True
92 | Resources.resx
93 |
94 |
95 |
96 |
97 |
98 | frmMyDlg.cs
99 |
100 |
101 | ResXFileCodeGenerator
102 | Resources.Designer.cs
103 | Designer
104 |
105 |
106 |
107 |
108 | False
109 | .NET Framework 3.5 SP1 Client Profile
110 | false
111 |
112 |
113 | False
114 | .NET Framework 3.5 SP1
115 | true
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
130 |
--------------------------------------------------------------------------------
/Merge files in one/Merge files in one.csproj.user:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 | en-US
11 | false
12 |
13 |
14 | Project
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/Merge files in one/Merge files in one.v11.suo:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/Merge files in one.v11.suo
--------------------------------------------------------------------------------
/Merge files in one/NppPluginNETBase.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace NppPluginNET
4 | {
5 | class PluginBase
6 | {
7 | #region " Fields "
8 | internal static NppData nppData;
9 | internal static FuncItems _funcItems = new FuncItems();
10 | #endregion
11 |
12 | #region " Helper "
13 | internal static void SetCommand(int index, string commandName, NppFuncItemDelegate functionPointer)
14 | {
15 | SetCommand(index, commandName, functionPointer, new ShortcutKey(), false);
16 | }
17 | internal static void SetCommand(int index, string commandName, NppFuncItemDelegate functionPointer, ShortcutKey shortcut)
18 | {
19 | SetCommand(index, commandName, functionPointer, shortcut, false);
20 | }
21 | internal static void SetCommand(int index, string commandName, NppFuncItemDelegate functionPointer, bool checkOnInit)
22 | {
23 | SetCommand(index, commandName, functionPointer, new ShortcutKey(), checkOnInit);
24 | }
25 | internal static void SetCommand(int index, string commandName, NppFuncItemDelegate functionPointer, ShortcutKey shortcut, bool checkOnInit)
26 | {
27 | FuncItem funcItem = new FuncItem();
28 | funcItem._cmdID = index;
29 | funcItem._itemName = commandName;
30 | if (functionPointer != null)
31 | funcItem._pFunc = new NppFuncItemDelegate(functionPointer);
32 | if (shortcut._key != 0)
33 | funcItem._pShKey = shortcut;
34 | funcItem._init2Check = checkOnInit;
35 | _funcItems.Add(funcItem);
36 | }
37 |
38 | internal static IntPtr GetCurrentScintilla()
39 | {
40 | int curScintilla;
41 | Win32.SendMessage(nppData._nppHandle, NppMsg.NPPM_GETCURRENTSCINTILLA, 0, out curScintilla);
42 | return (curScintilla == 0) ? nppData._scintillaMainHandle : nppData._scintillaSecondHandle;
43 | }
44 | #endregion
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/Merge files in one/NppPluginNETHelper.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Text;
3 | using System.Windows.Forms;
4 | using System.Collections.Generic;
5 | using System.Runtime.InteropServices;
6 |
7 | namespace NppPluginNET
8 | {
9 | #region " Notepad++ "
10 | [StructLayout(LayoutKind.Sequential)]
11 | public struct NppData
12 | {
13 | public IntPtr _nppHandle;
14 | public IntPtr _scintillaMainHandle;
15 | public IntPtr _scintillaSecondHandle;
16 | }
17 |
18 | public delegate void NppFuncItemDelegate();
19 |
20 | [StructLayout(LayoutKind.Sequential)]
21 | public struct ShortcutKey
22 | {
23 | public ShortcutKey(bool isCtrl, bool isAlt, bool isShift, Keys key)
24 | {
25 | // the types 'bool' and 'char' have a size of 1 byte only!
26 | _isCtrl = Convert.ToByte(isCtrl);
27 | _isAlt = Convert.ToByte(isAlt);
28 | _isShift = Convert.ToByte(isShift);
29 | _key = Convert.ToByte(key);
30 | }
31 | public byte _isCtrl;
32 | public byte _isAlt;
33 | public byte _isShift;
34 | public byte _key;
35 | }
36 |
37 | [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
38 | public struct FuncItem
39 | {
40 | [MarshalAs(UnmanagedType.ByValTStr, SizeConst = 64)]
41 | public string _itemName;
42 | public NppFuncItemDelegate _pFunc;
43 | public int _cmdID;
44 | public bool _init2Check;
45 | public ShortcutKey _pShKey;
46 | }
47 |
48 | public class FuncItems : IDisposable
49 | {
50 | List _funcItems;
51 | int _sizeFuncItem;
52 | List _shortCutKeys;
53 | IntPtr _nativePointer;
54 | bool _disposed = false;
55 |
56 | public FuncItems()
57 | {
58 | _funcItems = new List();
59 | _sizeFuncItem = Marshal.SizeOf(typeof(FuncItem));
60 | _shortCutKeys = new List();
61 | }
62 |
63 | [DllImport("kernel32")]
64 | static extern void RtlMoveMemory(IntPtr Destination, IntPtr Source, int Length);
65 | public void Add(FuncItem funcItem)
66 | {
67 | int oldSize = _funcItems.Count * _sizeFuncItem;
68 | _funcItems.Add(funcItem);
69 | int newSize = _funcItems.Count * _sizeFuncItem;
70 | IntPtr newPointer = Marshal.AllocHGlobal(newSize);
71 |
72 | if (_nativePointer != IntPtr.Zero)
73 | {
74 | RtlMoveMemory(newPointer, _nativePointer, oldSize);
75 | Marshal.FreeHGlobal(_nativePointer);
76 | }
77 | IntPtr ptrPosNewItem = (IntPtr)(newPointer.ToInt64() + oldSize);
78 | byte[] aB = Encoding.Unicode.GetBytes(funcItem._itemName + "\0");
79 | Marshal.Copy(aB, 0, ptrPosNewItem, aB.Length);
80 | ptrPosNewItem = (IntPtr)(ptrPosNewItem.ToInt64() + 128);
81 | IntPtr p = (funcItem._pFunc != null) ? Marshal.GetFunctionPointerForDelegate(funcItem._pFunc) : IntPtr.Zero;
82 | Marshal.WriteIntPtr(ptrPosNewItem, p);
83 | ptrPosNewItem = (IntPtr)(ptrPosNewItem.ToInt64() + IntPtr.Size);
84 | Marshal.WriteInt32(ptrPosNewItem, funcItem._cmdID);
85 | ptrPosNewItem = (IntPtr)(ptrPosNewItem.ToInt64() + 4);
86 | Marshal.WriteInt32(ptrPosNewItem, Convert.ToInt32(funcItem._init2Check));
87 | ptrPosNewItem = (IntPtr)(ptrPosNewItem.ToInt64() + 4);
88 | if (funcItem._pShKey._key != 0)
89 | {
90 | IntPtr newShortCutKey = Marshal.AllocHGlobal(4);
91 | Marshal.StructureToPtr(funcItem._pShKey, newShortCutKey, false);
92 | Marshal.WriteIntPtr(ptrPosNewItem, newShortCutKey);
93 | }
94 | else Marshal.WriteIntPtr(ptrPosNewItem, IntPtr.Zero);
95 |
96 | _nativePointer = newPointer;
97 | }
98 |
99 | public void RefreshItems()
100 | {
101 | IntPtr ptrPosItem = _nativePointer;
102 | for (int i = 0; i < _funcItems.Count; i++)
103 | {
104 | FuncItem updatedItem = new FuncItem();
105 | updatedItem._itemName = _funcItems[i]._itemName;
106 | ptrPosItem = (IntPtr)(ptrPosItem.ToInt64() + 128);
107 | updatedItem._pFunc = _funcItems[i]._pFunc;
108 | ptrPosItem = (IntPtr)(ptrPosItem.ToInt64() + IntPtr.Size);
109 | updatedItem._cmdID = Marshal.ReadInt32(ptrPosItem);
110 | ptrPosItem = (IntPtr)(ptrPosItem.ToInt64() + 4);
111 | updatedItem._init2Check = _funcItems[i]._init2Check;
112 | ptrPosItem = (IntPtr)(ptrPosItem.ToInt64() + 4);
113 | updatedItem._pShKey = _funcItems[i]._pShKey;
114 | ptrPosItem = (IntPtr)(ptrPosItem.ToInt64() + IntPtr.Size);
115 |
116 | _funcItems[i] = updatedItem;
117 | }
118 | }
119 |
120 | public IntPtr NativePointer { get { return _nativePointer; } }
121 | public List Items { get { return _funcItems; } }
122 |
123 | public void Dispose()
124 | {
125 | if (!_disposed)
126 | {
127 | foreach (IntPtr ptr in _shortCutKeys) Marshal.FreeHGlobal(ptr);
128 | if (_nativePointer != IntPtr.Zero) Marshal.FreeHGlobal(_nativePointer);
129 | _disposed = true;
130 | }
131 | }
132 | ~FuncItems()
133 | {
134 | Dispose();
135 | }
136 | }
137 |
138 | [StructLayout(LayoutKind.Sequential)]
139 | public struct RECT
140 | {
141 | public RECT(int left, int top, int right, int bottom)
142 | {
143 | Left = left; Top = top; Right = right; Bottom = bottom;
144 | }
145 | public int Left;
146 | public int Top;
147 | public int Right;
148 | public int Bottom;
149 | }
150 |
151 | [Flags]
152 | public enum NppTbMsg : uint
153 | {
154 | // styles for containers
155 | //CAPTION_TOP = 1,
156 | //CAPTION_BOTTOM = 0,
157 |
158 | // defines for docking manager
159 | CONT_LEFT = 0,
160 | CONT_RIGHT = 1,
161 | CONT_TOP = 2,
162 | CONT_BOTTOM = 3,
163 | DOCKCONT_MAX = 4,
164 |
165 | // mask params for plugins of internal dialogs
166 | DWS_ICONTAB = 0x00000001, // Icon for tabs are available
167 | DWS_ICONBAR = 0x00000002, // Icon for icon bar are available (currently not supported)
168 | DWS_ADDINFO = 0x00000004, // Additional information are in use
169 | DWS_PARAMSALL = (DWS_ICONTAB|DWS_ICONBAR|DWS_ADDINFO),
170 |
171 | // default docking values for first call of plugin
172 | DWS_DF_CONT_LEFT = (CONT_LEFT << 28), // default docking on left
173 | DWS_DF_CONT_RIGHT = (CONT_RIGHT << 28), // default docking on right
174 | DWS_DF_CONT_TOP = (CONT_TOP << 28), // default docking on top
175 | DWS_DF_CONT_BOTTOM = (CONT_BOTTOM << 28), // default docking on bottom
176 | DWS_DF_FLOATING = 0x80000000 // default state is floating
177 | }
178 |
179 | [StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
180 | public struct NppTbData
181 | {
182 | public IntPtr hClient; // HWND: client Window Handle
183 | public string pszName; // TCHAR*: name of plugin (shown in window)
184 | public int dlgID; // int: a funcItem provides the function pointer to start a dialog. Please parse here these ID
185 | // user modifications
186 | public NppTbMsg uMask; // UINT: mask params: look to above defines
187 | public uint hIconTab; // HICON: icon for tabs
188 | public string pszAddInfo; // TCHAR*: for plugin to display additional informations
189 | // internal data, do not use !!!
190 | public RECT rcFloat; // RECT: floating position
191 | public int iPrevCont; // int: stores the privious container (toggling between float and dock)
192 | public string pszModuleName; // const TCHAR*: it's the plugin file name. It's used to identify the plugin
193 | }
194 |
195 | public enum LangType
196 | {
197 | L_TEXT, L_PHP , L_C, L_CPP, L_CS, L_OBJC, L_JAVA, L_RC,
198 | L_HTML, L_XML, L_MAKEFILE, L_PASCAL, L_BATCH, L_INI, L_ASCII, L_USER,
199 | L_ASP, L_SQL, L_VB, L_JS, L_CSS, L_PERL, L_PYTHON, L_LUA,
200 | L_TEX, L_FORTRAN, L_BASH, L_FLASH, L_NSIS, L_TCL, L_LISP, L_SCHEME,
201 | L_ASM, L_DIFF, L_PROPS, L_PS, L_RUBY, L_SMALLTALK, L_VHDL, L_KIX, L_AU3,
202 | L_CAML, L_ADA, L_VERILOG, L_MATLAB, L_HASKELL, L_INNO, L_SEARCHRESULT,
203 | L_CMAKE, L_YAML, L_COBOL, L_GUI4CLI, L_D, L_POWERSHELL, L_R, L_JSP,
204 | // The end of enumated language type, so it should be always at the end
205 | L_EXTERNAL
206 | }
207 |
208 | [Flags]
209 | public enum NppMsg : uint
210 | {
211 | //Here you can find how to use these messages : http://notepad-plus.sourceforge.net/uk/plugins-HOWTO.php
212 | NPPMSG = (0x400/*WM_USER*/ + 1000),
213 |
214 | NPPM_GETCURRENTSCINTILLA = (NPPMSG + 4),
215 | NPPM_GETCURRENTLANGTYPE = (NPPMSG + 5),
216 | NPPM_SETCURRENTLANGTYPE = (NPPMSG + 6),
217 |
218 | NPPM_GETNBOPENFILES = (NPPMSG + 7),
219 | ALL_OPEN_FILES = 0,
220 | PRIMARY_VIEW = 1,
221 | SECOND_VIEW = 2,
222 |
223 | NPPM_GETOPENFILENAMES = (NPPMSG + 8),
224 |
225 | NPPM_MODELESSDIALOG = (NPPMSG + 12),
226 | MODELESSDIALOGADD = 0,
227 | MODELESSDIALOGREMOVE = 1,
228 |
229 | NPPM_GETNBSESSIONFILES = (NPPMSG + 13),
230 | NPPM_GETSESSIONFILES = (NPPMSG + 14),
231 | NPPM_SAVESESSION = (NPPMSG + 15),
232 | NPPM_SAVECURRENTSESSION = (NPPMSG + 16),
233 | //struct sessionInfo {
234 | // TCHAR* sessionFilePathName;
235 | // int nbFile;
236 | // TCHAR** files;
237 | //};
238 |
239 | NPPM_GETOPENFILENAMESPRIMARY = (NPPMSG + 17),
240 | NPPM_GETOPENFILENAMESSECOND = (NPPMSG + 18),
241 |
242 | NPPM_CREATESCINTILLAHANDLE = (NPPMSG + 20),
243 | NPPM_DESTROYSCINTILLAHANDLE = (NPPMSG + 21),
244 | NPPM_GETNBUSERLANG = (NPPMSG + 22),
245 |
246 | NPPM_GETCURRENTDOCINDEX = (NPPMSG + 23),
247 | MAIN_VIEW = 0,
248 | SUB_VIEW = 1,
249 |
250 | NPPM_SETSTATUSBAR = (NPPMSG + 24),
251 | STATUSBAR_DOC_TYPE = 0,
252 | STATUSBAR_DOC_SIZE = 1,
253 | STATUSBAR_CUR_POS = 2,
254 | STATUSBAR_EOF_FORMAT = 3,
255 | STATUSBAR_UNICODE_TYPE = 4,
256 | STATUSBAR_TYPING_MODE = 5,
257 |
258 | NPPM_GETMENUHANDLE = (NPPMSG + 25),
259 | NPPPLUGINMENU = 0,
260 |
261 | NPPM_ENCODESCI = (NPPMSG + 26),
262 | //ascii file to unicode
263 | //int NPPM_ENCODESCI(MAIN_VIEW/SUB_VIEW, 0)
264 | //return new unicodeMode
265 |
266 | NPPM_DECODESCI = (NPPMSG + 27),
267 | //unicode file to ascii
268 | //int NPPM_DECODESCI(MAIN_VIEW/SUB_VIEW, 0)
269 | //return old unicodeMode
270 |
271 | NPPM_ACTIVATEDOC = (NPPMSG + 28),
272 | //void NPPM_ACTIVATEDOC(int view, int index2Activate)
273 |
274 | NPPM_LAUNCHFINDINFILESDLG = (NPPMSG + 29),
275 | //void NPPM_LAUNCHFINDINFILESDLG(TCHAR * dir2Search, TCHAR * filtre)
276 |
277 | NPPM_DMMSHOW = (NPPMSG + 30),
278 | NPPM_DMMHIDE = (NPPMSG + 31),
279 | NPPM_DMMUPDATEDISPINFO = (NPPMSG + 32),
280 | //void NPPM_DMMxxx(0, tTbData->hClient)
281 |
282 | NPPM_DMMREGASDCKDLG = (NPPMSG + 33),
283 | //void NPPM_DMMREGASDCKDLG(0, &tTbData)
284 |
285 | NPPM_LOADSESSION = (NPPMSG + 34),
286 | //void NPPM_LOADSESSION(0, const TCHAR* file name)
287 |
288 | NPPM_DMMVIEWOTHERTAB = (NPPMSG + 35),
289 | //void WM_DMM_VIEWOTHERTAB(0, tTbData->pszName)
290 |
291 | NPPM_RELOADFILE = (NPPMSG + 36),
292 | //BOOL NPPM_RELOADFILE(BOOL withAlert, TCHAR *filePathName2Reload)
293 |
294 | NPPM_SWITCHTOFILE = (NPPMSG + 37),
295 | //BOOL NPPM_SWITCHTOFILE(0, TCHAR *filePathName2switch)
296 |
297 | NPPM_SAVECURRENTFILE = (NPPMSG + 38),
298 | //BOOL NPPM_SAVECURRENTFILE(0, 0)
299 |
300 | NPPM_SAVEALLFILES = (NPPMSG + 39),
301 | //BOOL NPPM_SAVEALLFILES(0, 0)
302 |
303 | NPPM_SETMENUITEMCHECK = (NPPMSG + 40),
304 | //void WM_PIMENU_CHECK(UINT funcItem[X]._cmdID, TRUE/FALSE)
305 |
306 | NPPM_ADDTOOLBARICON = (NPPMSG + 41),
307 | //void WM_ADDTOOLBARICON(UINT funcItem[X]._cmdID, toolbarIcons icon)
308 | //struct toolbarIcons {
309 | // HBITMAP hToolbarBmp;
310 | // HICON hToolbarIcon;
311 | //};
312 |
313 | NPPM_GETWINDOWSVERSION = (NPPMSG + 42),
314 | //winVer NPPM_GETWINDOWSVERSION(0, 0)
315 |
316 | NPPM_DMMGETPLUGINHWNDBYNAME = (NPPMSG + 43),
317 | //HWND WM_DMM_GETPLUGINHWNDBYNAME(const TCHAR *windowName, const TCHAR *moduleName)
318 | // if moduleName is NULL, then return value is NULL
319 | // if windowName is NULL, then the first found window handle which matches with the moduleName will be returned
320 |
321 | NPPM_MAKECURRENTBUFFERDIRTY = (NPPMSG + 44),
322 | //BOOL NPPM_MAKECURRENTBUFFERDIRTY(0, 0)
323 |
324 | NPPM_GETENABLETHEMETEXTUREFUNC = (NPPMSG + 45),
325 | //BOOL NPPM_GETENABLETHEMETEXTUREFUNC(0, 0)
326 |
327 | NPPM_GETPLUGINSCONFIGDIR = (NPPMSG + 46),
328 | //void NPPM_GETPLUGINSCONFIGDIR(int strLen, TCHAR *str)
329 |
330 | NPPM_MSGTOPLUGIN = (NPPMSG + 47),
331 | //BOOL NPPM_MSGTOPLUGIN(TCHAR *destModuleName, CommunicationInfo *info)
332 | // return value is TRUE when the message arrive to the destination plugins.
333 | // if destModule or info is NULL, then return value is FALSE
334 | //struct CommunicationInfo {
335 | // long internalMsg;
336 | // const TCHAR * srcModuleName;
337 | // void * info; // defined by plugin
338 | //};
339 |
340 | NPPM_MENUCOMMAND = (NPPMSG + 48),
341 | //void NPPM_MENUCOMMAND(0, int cmdID)
342 | // uncomment //#include "menuCmdID.h"
343 | // in the beginning of this file then use the command symbols defined in "menuCmdID.h" file
344 | // to access all the Notepad++ menu command items
345 |
346 | NPPM_TRIGGERTABBARCONTEXTMENU = (NPPMSG + 49),
347 | //void NPPM_TRIGGERTABBARCONTEXTMENU(int view, int index2Activate)
348 |
349 | NPPM_GETNPPVERSION = (NPPMSG + 50),
350 | // int NPPM_GETNPPVERSION(0, 0)
351 | // return version
352 | // ex : v4.6
353 | // HIWORD(version) == 4
354 | // LOWORD(version) == 6
355 |
356 | NPPM_HIDETABBAR = (NPPMSG + 51),
357 | // BOOL NPPM_HIDETABBAR(0, BOOL hideOrNot)
358 | // if hideOrNot is set as TRUE then tab bar will be hidden
359 | // otherwise it'll be shown.
360 | // return value : the old status value
361 |
362 | NPPM_ISTABBARHIDDEN = (NPPMSG + 52),
363 | // BOOL NPPM_ISTABBARHIDDEN(0, 0)
364 | // returned value : TRUE if tab bar is hidden, otherwise FALSE
365 |
366 | NPPM_GETPOSFROMBUFFERID = (NPPMSG + 57),
367 | // INT NPPM_GETPOSFROMBUFFERID(INT bufferID, 0)
368 | // Return VIEW|INDEX from a buffer ID. -1 if the bufferID non existing
369 | //
370 | // VIEW takes 2 highest bits and INDEX (0 based) takes the rest (30 bits)
371 | // Here's the values for the view :
372 | // MAIN_VIEW 0
373 | // SUB_VIEW 1
374 |
375 | NPPM_GETFULLPATHFROMBUFFERID = (NPPMSG + 58),
376 | // INT NPPM_GETFULLPATHFROMBUFFERID(INT bufferID, TCHAR *fullFilePath)
377 | // Get full path file name from a bufferID.
378 | // Return -1 if the bufferID non existing, otherwise the number of TCHAR copied/to copy
379 | // User should call it with fullFilePath be NULL to get the number of TCHAR (not including the nul character),
380 | // allocate fullFilePath with the return values + 1, then call it again to get full path file name
381 |
382 | NPPM_GETBUFFERIDFROMPOS = (NPPMSG + 59),
383 | //wParam: Position of document
384 | //lParam: View to use, 0 = Main, 1 = Secondary
385 | //Returns 0 if invalid
386 |
387 | NPPM_GETCURRENTBUFFERID = (NPPMSG + 60),
388 | //Returns active Buffer
389 |
390 | NPPM_RELOADBUFFERID = (NPPMSG + 61),
391 | //Reloads Buffer
392 | //wParam: Buffer to reload
393 | //lParam: 0 if no alert, else alert
394 |
395 |
396 | NPPM_GETBUFFERLANGTYPE = (NPPMSG + 64),
397 | //wParam: BufferID to get LangType from
398 | //lParam: 0
399 | //Returns as int, see LangType. -1 on error
400 |
401 | NPPM_SETBUFFERLANGTYPE = (NPPMSG + 65),
402 | //wParam: BufferID to set LangType of
403 | //lParam: LangType
404 | //Returns TRUE on success, FALSE otherwise
405 | //use int, see LangType for possible values
406 | //L_USER and L_EXTERNAL are not supported
407 |
408 | NPPM_GETBUFFERENCODING = (NPPMSG + 66),
409 | //wParam: BufferID to get encoding from
410 | //lParam: 0
411 | //returns as int, see UniMode. -1 on error
412 |
413 | NPPM_SETBUFFERENCODING = (NPPMSG + 67),
414 | //wParam: BufferID to set encoding of
415 | //lParam: format
416 | //Returns TRUE on success, FALSE otherwise
417 | //use int, see UniMode
418 | //Can only be done on new, unedited files
419 |
420 | NPPM_GETBUFFERFORMAT = (NPPMSG + 68),
421 | //wParam: BufferID to get format from
422 | //lParam: 0
423 | //returns as int, see formatType. -1 on error
424 |
425 | NPPM_SETBUFFERFORMAT = (NPPMSG + 69),
426 | //wParam: BufferID to set format of
427 | //lParam: format
428 | //Returns TRUE on success, FALSE otherwise
429 | //use int, see formatType
430 |
431 | /*
432 | NPPM_ADDREBAR = (NPPMSG + 57),
433 | // BOOL NPPM_ADDREBAR(0, REBARBANDINFO *)
434 | // Returns assigned ID in wID value of struct pointer
435 | NPPM_UPDATEREBAR = (NPPMSG + 58),
436 | // BOOL NPPM_ADDREBAR(INT ID, REBARBANDINFO *)
437 | //Use ID assigned with NPPM_ADDREBAR
438 | NPPM_REMOVEREBAR = (NPPMSG + 59),
439 | // BOOL NPPM_ADDREBAR(INT ID, 0)
440 | //Use ID assigned with NPPM_ADDREBAR
441 | */
442 |
443 | NPPM_HIDETOOLBAR = (NPPMSG + 70),
444 | // BOOL NPPM_HIDETOOLBAR(0, BOOL hideOrNot)
445 | // if hideOrNot is set as TRUE then tool bar will be hidden
446 | // otherwise it'll be shown.
447 | // return value : the old status value
448 |
449 | NPPM_ISTOOLBARHIDDEN = (NPPMSG + 71),
450 | // BOOL NPPM_ISTOOLBARHIDDEN(0, 0)
451 | // returned value : TRUE if tool bar is hidden, otherwise FALSE
452 |
453 | NPPM_HIDEMENU = (NPPMSG + 72),
454 | // BOOL NPPM_HIDEMENU(0, BOOL hideOrNot)
455 | // if hideOrNot is set as TRUE then menu will be hidden
456 | // otherwise it'll be shown.
457 | // return value : the old status value
458 |
459 | NPPM_ISMENUHIDDEN = (NPPMSG + 73),
460 | // BOOL NPPM_ISMENUHIDDEN(0, 0)
461 | // returned value : TRUE if menu is hidden, otherwise FALSE
462 |
463 | NPPM_HIDESTATUSBAR = (NPPMSG + 74),
464 | // BOOL NPPM_HIDESTATUSBAR(0, BOOL hideOrNot)
465 | // if hideOrNot is set as TRUE then STATUSBAR will be hidden
466 | // otherwise it'll be shown.
467 | // return value : the old status value
468 |
469 | NPPM_ISSTATUSBARHIDDEN = (NPPMSG + 75),
470 | // BOOL NPPM_ISSTATUSBARHIDDEN(0, 0)
471 | // returned value : TRUE if STATUSBAR is hidden, otherwise FALSE
472 |
473 | NPPM_GETSHORTCUTBYCMDID = (NPPMSG + 76),
474 | // BOOL NPPM_GETSHORTCUTBYCMDID(int cmdID, ShortcutKey *sk)
475 | // get your plugin command current mapped shortcut into sk via cmdID
476 | // You may need it after getting NPPN_READY notification
477 | // returned value : TRUE if this function call is successful and shorcut is enable, otherwise FALSE
478 |
479 | NPPM_DOOPEN = (NPPMSG + 77),
480 | // BOOL NPPM_DOOPEN(0, const TCHAR *fullPathName2Open)
481 | // fullPathName2Open indicates the full file path name to be opened.
482 | // The return value is TRUE (1) if the operation is successful, otherwise FALSE (0).
483 |
484 | NPPM_SAVECURRENTFILEAS = (NPPMSG + 78),
485 | // BOOL NPPM_SAVECURRENTFILEAS (BOOL asCopy, const TCHAR* filename)
486 |
487 | NPPM_GETCURRENTNATIVELANGENCODING = (NPPMSG + 79),
488 | // INT NPPM_GETCURRENTNATIVELANGENCODING(0, 0)
489 | // returned value : the current native language enconding
490 |
491 | NPPM_ALLOCATESUPPORTED = (NPPMSG + 80),
492 | // returns TRUE if NPPM_ALLOCATECMDID is supported
493 | // Use to identify if subclassing is necessary
494 |
495 | NPPM_ALLOCATECMDID = (NPPMSG + 81),
496 | // BOOL NPPM_ALLOCATECMDID(int numberRequested, int* startNumber)
497 | // sets startNumber to the initial command ID if successful
498 | // Returns: TRUE if successful, FALSE otherwise. startNumber will also be set to 0 if unsuccessful
499 | NPPM_GETPLUGINHOMEPATH = (NPPMSG + 97),
500 |
501 | NPPM_ALLOCATEMARKER = (NPPMSG + 82),
502 | // BOOL NPPM_ALLOCATEMARKER(int numberRequested, int* startNumber)
503 | // sets startNumber to the initial command ID if successful
504 | // Allocates a marker number to a plugin
505 | // Returns: TRUE if successful, FALSE otherwise. startNumber will also be set to 0 if unsuccessful
506 |
507 | RUNCOMMAND_USER = (0x400/*WM_USER*/ + 3000),
508 | NPPM_GETFULLCURRENTPATH = (RUNCOMMAND_USER + FULL_CURRENT_PATH),
509 | NPPM_GETCURRENTDIRECTORY = (RUNCOMMAND_USER + CURRENT_DIRECTORY),
510 | NPPM_GETFILENAME = (RUNCOMMAND_USER + FILE_NAME),
511 | NPPM_GETNAMEPART = (RUNCOMMAND_USER + NAME_PART),
512 | NPPM_GETEXTPART = (RUNCOMMAND_USER + EXT_PART),
513 | NPPM_GETCURRENTWORD = (RUNCOMMAND_USER + CURRENT_WORD),
514 | NPPM_GETNPPDIRECTORY = (RUNCOMMAND_USER + NPP_DIRECTORY),
515 | // BOOL NPPM_GETXXXXXXXXXXXXXXXX(size_t strLen, TCHAR *str)
516 | // where str is the allocated TCHAR array,
517 | // strLen is the allocated array size
518 | // The return value is TRUE when get generic_string operation success
519 | // Otherwise (allocated array size is too small) FALSE
520 |
521 | NPPM_GETCURRENTLINE = (RUNCOMMAND_USER + CURRENT_LINE),
522 | // INT NPPM_GETCURRENTLINE(0, 0)
523 | // return the caret current position line
524 | NPPM_GETCURRENTCOLUMN = (RUNCOMMAND_USER + CURRENT_COLUMN),
525 | // INT NPPM_GETCURRENTCOLUMN(0, 0)
526 | // return the caret current position column
527 | VAR_NOT_RECOGNIZED = 0,
528 | FULL_CURRENT_PATH = 1,
529 | CURRENT_DIRECTORY = 2,
530 | FILE_NAME = 3,
531 | NAME_PART = 4,
532 | EXT_PART = 5,
533 | CURRENT_WORD = 6,
534 | NPP_DIRECTORY = 7,
535 | CURRENT_LINE = 8,
536 | CURRENT_COLUMN = 9,
537 |
538 | // Notification code
539 | NPPN_FIRST = 1000,
540 | NPPN_READY = (NPPN_FIRST + 1), // To notify plugins that all the procedures of launchment of notepad++ are done.
541 | //scnNotification->nmhdr.code = NPPN_READY;
542 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
543 | //scnNotification->nmhdr.idFrom = 0;
544 |
545 | NPPN_TBMODIFICATION = (NPPN_FIRST + 2), // To notify plugins that toolbar icons can be registered
546 | //scnNotification->nmhdr.code = NPPN_TB_MODIFICATION;
547 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
548 | //scnNotification->nmhdr.idFrom = 0;
549 |
550 | NPPN_FILEBEFORECLOSE = (NPPN_FIRST + 3), // To notify plugins that the current file is about to be closed
551 | //scnNotification->nmhdr.code = NPPN_FILEBEFORECLOSE;
552 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
553 | //scnNotification->nmhdr.idFrom = BufferID;
554 |
555 | NPPN_FILEOPENED = (NPPN_FIRST + 4), // To notify plugins that the current file is just opened
556 | //scnNotification->nmhdr.code = NPPN_FILEOPENED;
557 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
558 | //scnNotification->nmhdr.idFrom = BufferID;
559 |
560 | NPPN_FILECLOSED = (NPPN_FIRST + 5), // To notify plugins that the current file is just closed
561 | //scnNotification->nmhdr.code = NPPN_FILECLOSED;
562 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
563 | //scnNotification->nmhdr.idFrom = BufferID;
564 |
565 | NPPN_FILEBEFOREOPEN = (NPPN_FIRST + 6), // To notify plugins that the current file is about to be opened
566 | //scnNotification->nmhdr.code = NPPN_FILEBEFOREOPEN;
567 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
568 | //scnNotification->nmhdr.idFrom = BufferID;
569 |
570 | NPPN_FILEBEFORESAVE = (NPPN_FIRST + 7), // To notify plugins that the current file is about to be saved
571 | //scnNotification->nmhdr.code = NPPN_FILEBEFOREOPEN;
572 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
573 | //scnNotification->nmhdr.idFrom = BufferID;
574 |
575 | NPPN_FILESAVED = (NPPN_FIRST + 8), // To notify plugins that the current file is just saved
576 | //scnNotification->nmhdr.code = NPPN_FILESAVED;
577 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
578 | //scnNotification->nmhdr.idFrom = BufferID;
579 |
580 | NPPN_SHUTDOWN = (NPPN_FIRST + 9), // To notify plugins that Notepad++ is about to be shutdowned.
581 | //scnNotification->nmhdr.code = NPPN_SHUTDOWN;
582 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
583 | //scnNotification->nmhdr.idFrom = 0;
584 |
585 | NPPN_BUFFERACTIVATED = (NPPN_FIRST + 10), // To notify plugins that a buffer was activated (put to foreground).
586 | //scnNotification->nmhdr.code = NPPN_BUFFERACTIVATED;
587 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
588 | //scnNotification->nmhdr.idFrom = activatedBufferID;
589 |
590 | NPPN_LANGCHANGED = (NPPN_FIRST + 11), // To notify plugins that the language in the current doc is just changed.
591 | //scnNotification->nmhdr.code = NPPN_LANGCHANGED;
592 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
593 | //scnNotification->nmhdr.idFrom = currentBufferID;
594 |
595 | NPPN_WORDSTYLESUPDATED = (NPPN_FIRST + 12), // To notify plugins that user initiated a WordStyleDlg change.
596 | //scnNotification->nmhdr.code = NPPN_WORDSTYLESUPDATED;
597 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
598 | //scnNotification->nmhdr.idFrom = currentBufferID;
599 |
600 | NPPN_SHORTCUTREMAPPED = (NPPN_FIRST + 13), // To notify plugins that plugin command shortcut is remapped.
601 | //scnNotification->nmhdr.code = NPPN_SHORTCUTSREMAPPED;
602 | //scnNotification->nmhdr.hwndFrom = ShortcutKeyStructurePointer;
603 | //scnNotification->nmhdr.idFrom = cmdID;
604 | //where ShortcutKeyStructurePointer is pointer of struct ShortcutKey:
605 | //struct ShortcutKey {
606 | // bool _isCtrl;
607 | // bool _isAlt;
608 | // bool _isShift;
609 | // UCHAR _key;
610 | //};
611 |
612 | NPPN_FILEBEFORELOAD = (NPPN_FIRST + 14), // To notify plugins that the current file is about to be loaded
613 | //scnNotification->nmhdr.code = NPPN_FILEBEFOREOPEN;
614 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
615 | //scnNotification->nmhdr.idFrom = NULL;
616 |
617 | NPPN_FILELOADFAILED = (NPPN_FIRST + 15), // To notify plugins that file open operation failed
618 | //scnNotification->nmhdr.code = NPPN_FILEOPENFAILED;
619 | //scnNotification->nmhdr.hwndFrom = hwndNpp;
620 | //scnNotification->nmhdr.idFrom = BufferID;
621 |
622 | NPPN_READONLYCHANGED = (NPPN_FIRST + 16), // To notify plugins that current document change the readonly status,
623 | //scnNotification->nmhdr.code = NPPN_READONLYCHANGED;
624 | //scnNotification->nmhdr.hwndFrom = bufferID;
625 | //scnNotification->nmhdr.idFrom = docStatus;
626 | // where bufferID is BufferID
627 | // docStatus can be combined by DOCSTAUS_READONLY and DOCSTAUS_BUFFERDIRTY
628 |
629 | DOCSTAUS_READONLY = 1,
630 | DOCSTAUS_BUFFERDIRTY = 2,
631 |
632 | NPPN_DOCORDERCHANGED = (NPPN_FIRST + 16) // To notify plugins that document order is changed
633 | //scnNotification->nmhdr.code = NPPN_DOCORDERCHANGED;
634 | //scnNotification->nmhdr.hwndFrom = newIndex;
635 | //scnNotification->nmhdr.idFrom = BufferID;
636 | }
637 |
638 | public enum NppMenuCmd : uint
639 | {
640 | IDM = 40000,
641 |
642 | IDM_FILE = (IDM + 1000),
643 | IDM_FILE_NEW = (IDM_FILE + 1),
644 | IDM_FILE_OPEN = (IDM_FILE + 2),
645 | IDM_FILE_CLOSE = (IDM_FILE + 3),
646 | IDM_FILE_CLOSEALL = (IDM_FILE + 4),
647 | IDM_FILE_CLOSEALL_BUT_CURRENT = (IDM_FILE + 5),
648 | IDM_FILE_SAVE = (IDM_FILE + 6),
649 | IDM_FILE_SAVEALL = (IDM_FILE + 7),
650 | IDM_FILE_SAVEAS = (IDM_FILE + 8),
651 | //IDM_FILE_ASIAN_LANG = (IDM_FILE + 9),
652 | IDM_FILE_PRINT = (IDM_FILE + 10),
653 | IDM_FILE_PRINTNOW = 1001,
654 | IDM_FILE_EXIT = (IDM_FILE + 11),
655 | IDM_FILE_LOADSESSION = (IDM_FILE + 12),
656 | IDM_FILE_SAVESESSION = (IDM_FILE + 13),
657 | IDM_FILE_RELOAD = (IDM_FILE + 14),
658 | IDM_FILE_SAVECOPYAS = (IDM_FILE + 15),
659 | IDM_FILE_DELETE = (IDM_FILE + 16),
660 | IDM_FILE_RENAME = (IDM_FILE + 17),
661 |
662 | // A mettre à jour si on ajoute nouveau menu item dans le menu "File"
663 | IDM_FILEMENU_LASTONE = IDM_FILE_RENAME,
664 |
665 | IDM_EDIT = (IDM + 2000),
666 | IDM_EDIT_CUT = (IDM_EDIT + 1),
667 | IDM_EDIT_COPY = (IDM_EDIT + 2),
668 | IDM_EDIT_UNDO = (IDM_EDIT + 3),
669 | IDM_EDIT_REDO = (IDM_EDIT + 4),
670 | IDM_EDIT_PASTE = (IDM_EDIT + 5),
671 | IDM_EDIT_DELETE = (IDM_EDIT + 6),
672 | IDM_EDIT_SELECTALL = (IDM_EDIT + 7),
673 |
674 | IDM_EDIT_INS_TAB = (IDM_EDIT + 8),
675 | IDM_EDIT_RMV_TAB = (IDM_EDIT + 9),
676 | IDM_EDIT_DUP_LINE = (IDM_EDIT + 10),
677 | IDM_EDIT_TRANSPOSE_LINE = (IDM_EDIT + 11),
678 | IDM_EDIT_SPLIT_LINES = (IDM_EDIT + 12),
679 | IDM_EDIT_JOIN_LINES = (IDM_EDIT + 13),
680 | IDM_EDIT_LINE_UP = (IDM_EDIT + 14),
681 | IDM_EDIT_LINE_DOWN = (IDM_EDIT + 15),
682 | IDM_EDIT_UPPERCASE = (IDM_EDIT + 16),
683 | IDM_EDIT_LOWERCASE = (IDM_EDIT + 17),
684 |
685 | // Menu macro
686 | IDM_MACRO_STARTRECORDINGMACRO = (IDM_EDIT + 18),
687 | IDM_MACRO_STOPRECORDINGMACRO = (IDM_EDIT + 19),
688 | IDM_MACRO_PLAYBACKRECORDEDMACRO = (IDM_EDIT + 21),
689 | //-----------
690 |
691 | IDM_EDIT_BLOCK_COMMENT = (IDM_EDIT + 22),
692 | IDM_EDIT_STREAM_COMMENT = (IDM_EDIT + 23),
693 | IDM_EDIT_TRIMTRAILING = (IDM_EDIT + 24),
694 | IDM_EDIT_TRIMLINEHEAD = (IDM_EDIT + 42),
695 | IDM_EDIT_TRIM_BOTH = (IDM_EDIT + 43),
696 | IDM_EDIT_EOL2WS = (IDM_EDIT + 44),
697 | IDM_EDIT_TRIMALL = (IDM_EDIT + 45),
698 | IDM_EDIT_TAB2SW = (IDM_EDIT + 46),
699 | IDM_EDIT_SW2TAB = (IDM_EDIT + 47),
700 |
701 | // Menu macro
702 | IDM_MACRO_SAVECURRENTMACRO = (IDM_EDIT + 25),
703 | //-----------
704 |
705 | IDM_EDIT_RTL = (IDM_EDIT + 26),
706 | IDM_EDIT_LTR = (IDM_EDIT + 27),
707 | IDM_EDIT_SETREADONLY = (IDM_EDIT + 28),
708 | IDM_EDIT_FULLPATHTOCLIP = (IDM_EDIT + 29),
709 | IDM_EDIT_FILENAMETOCLIP = (IDM_EDIT + 30),
710 | IDM_EDIT_CURRENTDIRTOCLIP = (IDM_EDIT + 31),
711 |
712 | // Menu macro
713 | IDM_MACRO_RUNMULTIMACRODLG = (IDM_EDIT + 32),
714 | //-----------
715 |
716 | IDM_EDIT_CLEARREADONLY = (IDM_EDIT + 33),
717 | IDM_EDIT_COLUMNMODE = (IDM_EDIT + 34),
718 | IDM_EDIT_BLOCK_COMMENT_SET = (IDM_EDIT + 35),
719 | IDM_EDIT_BLOCK_UNCOMMENT = (IDM_EDIT + 36),
720 |
721 | IDM_EDIT_AUTOCOMPLETE = (50000 + 0),
722 | IDM_EDIT_AUTOCOMPLETE_CURRENTFILE = (50000 + 1),
723 | IDM_EDIT_FUNCCALLTIP = (50000 + 2),
724 |
725 | //Belong to MENU FILE
726 | IDM_OPEN_ALL_RECENT_FILE = (IDM_EDIT + 40),
727 | IDM_CLEAN_RECENT_FILE_LIST = (IDM_EDIT + 41),
728 |
729 | IDM_SEARCH = (IDM + 3000),
730 |
731 | IDM_SEARCH_FIND = (IDM_SEARCH + 1),
732 | IDM_SEARCH_FINDNEXT = (IDM_SEARCH + 2),
733 | IDM_SEARCH_REPLACE = (IDM_SEARCH + 3),
734 | IDM_SEARCH_GOTOLINE = (IDM_SEARCH + 4),
735 | IDM_SEARCH_TOGGLE_BOOKMARK = (IDM_SEARCH + 5),
736 | IDM_SEARCH_NEXT_BOOKMARK = (IDM_SEARCH + 6),
737 | IDM_SEARCH_PREV_BOOKMARK = (IDM_SEARCH + 7),
738 | IDM_SEARCH_CLEAR_BOOKMARKS = (IDM_SEARCH + 8),
739 | IDM_SEARCH_GOTOMATCHINGBRACE = (IDM_SEARCH + 9),
740 | IDM_SEARCH_FINDPREV = (IDM_SEARCH + 10),
741 | IDM_SEARCH_FINDINCREMENT = (IDM_SEARCH + 11),
742 | IDM_SEARCH_FINDINFILES = (IDM_SEARCH + 13),
743 | IDM_SEARCH_VOLATILE_FINDNEXT = (IDM_SEARCH + 14),
744 | IDM_SEARCH_VOLATILE_FINDPREV = (IDM_SEARCH + 15),
745 | IDM_SEARCH_CUTMARKEDLINES = (IDM_SEARCH + 18),
746 | IDM_SEARCH_COPYMARKEDLINES = (IDM_SEARCH + 19),
747 | IDM_SEARCH_PASTEMARKEDLINES = (IDM_SEARCH + 20),
748 | IDM_SEARCH_DELETEMARKEDLINES = (IDM_SEARCH + 21),
749 | IDM_SEARCH_MARKALLEXT1 = (IDM_SEARCH + 22),
750 | IDM_SEARCH_UNMARKALLEXT1 = (IDM_SEARCH + 23),
751 | IDM_SEARCH_MARKALLEXT2 = (IDM_SEARCH + 24),
752 | IDM_SEARCH_UNMARKALLEXT2 = (IDM_SEARCH + 25),
753 | IDM_SEARCH_MARKALLEXT3 = (IDM_SEARCH + 26),
754 | IDM_SEARCH_UNMARKALLEXT3 = (IDM_SEARCH + 27),
755 | IDM_SEARCH_MARKALLEXT4 = (IDM_SEARCH + 28),
756 | IDM_SEARCH_UNMARKALLEXT4 = (IDM_SEARCH + 29),
757 | IDM_SEARCH_MARKALLEXT5 = (IDM_SEARCH + 30),
758 | IDM_SEARCH_UNMARKALLEXT5 = (IDM_SEARCH + 31),
759 | IDM_SEARCH_CLEARALLMARKS = (IDM_SEARCH + 32),
760 |
761 | IDM_SEARCH_GOPREVMARKER1 = (IDM_SEARCH + 33),
762 | IDM_SEARCH_GOPREVMARKER2 = (IDM_SEARCH + 34),
763 | IDM_SEARCH_GOPREVMARKER3 = (IDM_SEARCH + 35),
764 | IDM_SEARCH_GOPREVMARKER4 = (IDM_SEARCH + 36),
765 | IDM_SEARCH_GOPREVMARKER5 = (IDM_SEARCH + 37),
766 | IDM_SEARCH_GOPREVMARKER_DEF = (IDM_SEARCH + 38),
767 |
768 | IDM_SEARCH_GONEXTMARKER1 = (IDM_SEARCH + 39),
769 | IDM_SEARCH_GONEXTMARKER2 = (IDM_SEARCH + 40),
770 | IDM_SEARCH_GONEXTMARKER3 = (IDM_SEARCH + 41),
771 | IDM_SEARCH_GONEXTMARKER4 = (IDM_SEARCH + 42),
772 | IDM_SEARCH_GONEXTMARKER5 = (IDM_SEARCH + 43),
773 | IDM_SEARCH_GONEXTMARKER_DEF = (IDM_SEARCH + 44),
774 |
775 | IDM_FOCUS_ON_FOUND_RESULTS = (IDM_SEARCH + 45),
776 | IDM_SEARCH_GOTONEXTFOUND = (IDM_SEARCH + 46),
777 | IDM_SEARCH_GOTOPREVFOUND = (IDM_SEARCH + 47),
778 |
779 | IDM_SEARCH_SETANDFINDNEXT = (IDM_SEARCH + 48),
780 | IDM_SEARCH_SETANDFINDPREV = (IDM_SEARCH + 49),
781 | IDM_SEARCH_INVERSEMARKS = (IDM_SEARCH + 50),
782 |
783 | IDM_VIEW = (IDM + 4000),
784 | //IDM_VIEW_TOOLBAR_HIDE = (IDM_VIEW + 1),
785 | IDM_VIEW_TOOLBAR_REDUCE = (IDM_VIEW + 2),
786 | IDM_VIEW_TOOLBAR_ENLARGE = (IDM_VIEW + 3),
787 | IDM_VIEW_TOOLBAR_STANDARD = (IDM_VIEW + 4),
788 | IDM_VIEW_REDUCETABBAR = (IDM_VIEW + 5),
789 | IDM_VIEW_LOCKTABBAR = (IDM_VIEW + 6),
790 | IDM_VIEW_DRAWTABBAR_TOPBAR = (IDM_VIEW + 7),
791 | IDM_VIEW_DRAWTABBAR_INACIVETAB = (IDM_VIEW + 8),
792 | IDM_VIEW_POSTIT = (IDM_VIEW + 9),
793 | IDM_VIEW_TOGGLE_FOLDALL = (IDM_VIEW + 10),
794 | IDM_VIEW_USER_DLG = (IDM_VIEW + 11),
795 | IDM_VIEW_LINENUMBER = (IDM_VIEW + 12),
796 | IDM_VIEW_SYMBOLMARGIN = (IDM_VIEW + 13),
797 | IDM_VIEW_FOLDERMAGIN = (IDM_VIEW + 14),
798 | IDM_VIEW_FOLDERMAGIN_SIMPLE = (IDM_VIEW + 15),
799 | IDM_VIEW_FOLDERMAGIN_ARROW = (IDM_VIEW + 16),
800 | IDM_VIEW_FOLDERMAGIN_CIRCLE = (IDM_VIEW + 17),
801 | IDM_VIEW_FOLDERMAGIN_BOX = (IDM_VIEW + 18),
802 | IDM_VIEW_ALL_CHARACTERS = (IDM_VIEW + 19),
803 | IDM_VIEW_INDENT_GUIDE = (IDM_VIEW + 20),
804 | IDM_VIEW_CURLINE_HILITING = (IDM_VIEW + 21),
805 | IDM_VIEW_WRAP = (IDM_VIEW + 22),
806 | IDM_VIEW_ZOOMIN = (IDM_VIEW + 23),
807 | IDM_VIEW_ZOOMOUT = (IDM_VIEW + 24),
808 | IDM_VIEW_TAB_SPACE = (IDM_VIEW + 25),
809 | IDM_VIEW_EOL = (IDM_VIEW + 26),
810 | IDM_VIEW_EDGELINE = (IDM_VIEW + 27),
811 | IDM_VIEW_EDGEBACKGROUND = (IDM_VIEW + 28),
812 | IDM_VIEW_TOGGLE_UNFOLDALL = (IDM_VIEW + 29),
813 | IDM_VIEW_FOLD_CURRENT = (IDM_VIEW + 30),
814 | IDM_VIEW_UNFOLD_CURRENT = (IDM_VIEW + 31),
815 | IDM_VIEW_FULLSCREENTOGGLE = (IDM_VIEW + 32),
816 | IDM_VIEW_ZOOMRESTORE = (IDM_VIEW + 33),
817 | IDM_VIEW_ALWAYSONTOP = (IDM_VIEW + 34),
818 | IDM_VIEW_SYNSCROLLV = (IDM_VIEW + 35),
819 | IDM_VIEW_SYNSCROLLH = (IDM_VIEW + 36),
820 | IDM_VIEW_EDGENONE = (IDM_VIEW + 37),
821 | IDM_VIEW_DRAWTABBAR_CLOSEBOTTUN = (IDM_VIEW + 38),
822 | IDM_VIEW_DRAWTABBAR_DBCLK2CLOSE = (IDM_VIEW + 39),
823 | IDM_VIEW_REFRESHTABAR = (IDM_VIEW + 40),
824 | IDM_VIEW_WRAP_SYMBOL = (IDM_VIEW + 41),
825 | IDM_VIEW_HIDELINES = (IDM_VIEW + 42),
826 | IDM_VIEW_DRAWTABBAR_VERTICAL = (IDM_VIEW + 43),
827 | IDM_VIEW_DRAWTABBAR_MULTILINE = (IDM_VIEW + 44),
828 | IDM_VIEW_DOCCHANGEMARGIN = (IDM_VIEW + 45),
829 | IDM_VIEW_LWDEF = (IDM_VIEW + 46),
830 | IDM_VIEW_LWALIGN = (IDM_VIEW + 47),
831 | IDM_VIEW_LWINDENT = (IDM_VIEW + 48),
832 | IDM_VIEW_SUMMARY = (IDM_VIEW + 49),
833 |
834 | IDM_VIEW_FOLD = (IDM_VIEW + 50),
835 | IDM_VIEW_FOLD_1 = (IDM_VIEW_FOLD + 1),
836 | IDM_VIEW_FOLD_2 = (IDM_VIEW_FOLD + 2),
837 | IDM_VIEW_FOLD_3 = (IDM_VIEW_FOLD + 3),
838 | IDM_VIEW_FOLD_4 = (IDM_VIEW_FOLD + 4),
839 | IDM_VIEW_FOLD_5 = (IDM_VIEW_FOLD + 5),
840 | IDM_VIEW_FOLD_6 = (IDM_VIEW_FOLD + 6),
841 | IDM_VIEW_FOLD_7 = (IDM_VIEW_FOLD + 7),
842 | IDM_VIEW_FOLD_8 = (IDM_VIEW_FOLD + 8),
843 |
844 | IDM_VIEW_UNFOLD = (IDM_VIEW + 60),
845 | IDM_VIEW_UNFOLD_1 = (IDM_VIEW_UNFOLD + 1),
846 | IDM_VIEW_UNFOLD_2 = (IDM_VIEW_UNFOLD + 2),
847 | IDM_VIEW_UNFOLD_3 = (IDM_VIEW_UNFOLD + 3),
848 | IDM_VIEW_UNFOLD_4 = (IDM_VIEW_UNFOLD + 4),
849 | IDM_VIEW_UNFOLD_5 = (IDM_VIEW_UNFOLD + 5),
850 | IDM_VIEW_UNFOLD_6 = (IDM_VIEW_UNFOLD + 6),
851 | IDM_VIEW_UNFOLD_7 = (IDM_VIEW_UNFOLD + 7),
852 | IDM_VIEW_UNFOLD_8 = (IDM_VIEW_UNFOLD + 8),
853 |
854 | IDM_VIEW_GOTO_ANOTHER_VIEW = 10001,
855 | IDM_VIEW_CLONE_TO_ANOTHER_VIEW = 10002,
856 | IDM_VIEW_GOTO_NEW_INSTANCE = 10003,
857 | IDM_VIEW_LOAD_IN_NEW_INSTANCE = 10004,
858 |
859 | IDM_VIEW_SWITCHTO_OTHER_VIEW = (IDM_VIEW + 72),
860 |
861 | IDM_FORMAT = (IDM + 5000),
862 | IDM_FORMAT_TODOS = (IDM_FORMAT + 1),
863 | IDM_FORMAT_TOUNIX = (IDM_FORMAT + 2),
864 | IDM_FORMAT_TOMAC = (IDM_FORMAT + 3),
865 | IDM_FORMAT_ANSI = (IDM_FORMAT + 4),
866 | IDM_FORMAT_UTF_8 = (IDM_FORMAT + 5),
867 | IDM_FORMAT_UCS_2BE = (IDM_FORMAT + 6),
868 | IDM_FORMAT_UCS_2LE = (IDM_FORMAT + 7),
869 | IDM_FORMAT_AS_UTF_8 = (IDM_FORMAT + 8),
870 | IDM_FORMAT_CONV2_ANSI = (IDM_FORMAT + 9),
871 | IDM_FORMAT_CONV2_AS_UTF_8 = (IDM_FORMAT + 10),
872 | IDM_FORMAT_CONV2_UTF_8 = (IDM_FORMAT + 11),
873 | IDM_FORMAT_CONV2_UCS_2BE = (IDM_FORMAT + 12),
874 | IDM_FORMAT_CONV2_UCS_2LE = (IDM_FORMAT + 13),
875 |
876 | IDM_FORMAT_ENCODE = (IDM_FORMAT + 20),
877 | IDM_FORMAT_WIN_1250 = (IDM_FORMAT_ENCODE + 0),
878 | IDM_FORMAT_WIN_1251 = (IDM_FORMAT_ENCODE + 1),
879 | IDM_FORMAT_WIN_1252 = (IDM_FORMAT_ENCODE + 2),
880 | IDM_FORMAT_WIN_1253 = (IDM_FORMAT_ENCODE + 3),
881 | IDM_FORMAT_WIN_1254 = (IDM_FORMAT_ENCODE + 4),
882 | IDM_FORMAT_WIN_1255 = (IDM_FORMAT_ENCODE + 5),
883 | IDM_FORMAT_WIN_1256 = (IDM_FORMAT_ENCODE + 6),
884 | IDM_FORMAT_WIN_1257 = (IDM_FORMAT_ENCODE + 7),
885 | IDM_FORMAT_WIN_1258 = (IDM_FORMAT_ENCODE + 8),
886 | IDM_FORMAT_ISO_8859_1 = (IDM_FORMAT_ENCODE + 9),
887 | IDM_FORMAT_ISO_8859_2 = (IDM_FORMAT_ENCODE + 10),
888 | IDM_FORMAT_ISO_8859_3 = (IDM_FORMAT_ENCODE + 11),
889 | IDM_FORMAT_ISO_8859_4 = (IDM_FORMAT_ENCODE + 12),
890 | IDM_FORMAT_ISO_8859_5 = (IDM_FORMAT_ENCODE + 13),
891 | IDM_FORMAT_ISO_8859_6 = (IDM_FORMAT_ENCODE + 14),
892 | IDM_FORMAT_ISO_8859_7 = (IDM_FORMAT_ENCODE + 15),
893 | IDM_FORMAT_ISO_8859_8 = (IDM_FORMAT_ENCODE + 16),
894 | IDM_FORMAT_ISO_8859_9 = (IDM_FORMAT_ENCODE + 17),
895 | IDM_FORMAT_ISO_8859_10 = (IDM_FORMAT_ENCODE + 18),
896 | IDM_FORMAT_ISO_8859_11 = (IDM_FORMAT_ENCODE + 19),
897 | IDM_FORMAT_ISO_8859_13 = (IDM_FORMAT_ENCODE + 20),
898 | IDM_FORMAT_ISO_8859_14 = (IDM_FORMAT_ENCODE + 21),
899 | IDM_FORMAT_ISO_8859_15 = (IDM_FORMAT_ENCODE + 22),
900 | IDM_FORMAT_ISO_8859_16 = (IDM_FORMAT_ENCODE + 23),
901 | IDM_FORMAT_DOS_437 = (IDM_FORMAT_ENCODE + 24),
902 | IDM_FORMAT_DOS_720 = (IDM_FORMAT_ENCODE + 25),
903 | IDM_FORMAT_DOS_737 = (IDM_FORMAT_ENCODE + 26),
904 | IDM_FORMAT_DOS_775 = (IDM_FORMAT_ENCODE + 27),
905 | IDM_FORMAT_DOS_850 = (IDM_FORMAT_ENCODE + 28),
906 | IDM_FORMAT_DOS_852 = (IDM_FORMAT_ENCODE + 29),
907 | IDM_FORMAT_DOS_855 = (IDM_FORMAT_ENCODE + 30),
908 | IDM_FORMAT_DOS_857 = (IDM_FORMAT_ENCODE + 31),
909 | IDM_FORMAT_DOS_858 = (IDM_FORMAT_ENCODE + 32),
910 | IDM_FORMAT_DOS_860 = (IDM_FORMAT_ENCODE + 33),
911 | IDM_FORMAT_DOS_861 = (IDM_FORMAT_ENCODE + 34),
912 | IDM_FORMAT_DOS_862 = (IDM_FORMAT_ENCODE + 35),
913 | IDM_FORMAT_DOS_863 = (IDM_FORMAT_ENCODE + 36),
914 | IDM_FORMAT_DOS_865 = (IDM_FORMAT_ENCODE + 37),
915 | IDM_FORMAT_DOS_866 = (IDM_FORMAT_ENCODE + 38),
916 | IDM_FORMAT_DOS_869 = (IDM_FORMAT_ENCODE + 39),
917 | IDM_FORMAT_BIG5 = (IDM_FORMAT_ENCODE + 40),
918 | IDM_FORMAT_GB2312 = (IDM_FORMAT_ENCODE + 41),
919 | IDM_FORMAT_SHIFT_JIS = (IDM_FORMAT_ENCODE + 42),
920 | IDM_FORMAT_KOREAN_WIN = (IDM_FORMAT_ENCODE + 43),
921 | IDM_FORMAT_EUC_KR = (IDM_FORMAT_ENCODE + 44),
922 | IDM_FORMAT_TIS_620 = (IDM_FORMAT_ENCODE + 45),
923 | IDM_FORMAT_MAC_CYRILLIC = (IDM_FORMAT_ENCODE + 46),
924 | IDM_FORMAT_KOI8U_CYRILLIC = (IDM_FORMAT_ENCODE + 47),
925 | IDM_FORMAT_KOI8R_CYRILLIC = (IDM_FORMAT_ENCODE + 48),
926 | IDM_FORMAT_ENCODE_END = IDM_FORMAT_KOI8R_CYRILLIC,
927 |
928 | //#define IDM_FORMAT_CONVERT 200
929 |
930 | IDM_LANG = (IDM + 6000),
931 | IDM_LANGSTYLE_CONFIG_DLG = (IDM_LANG + 1),
932 | IDM_LANG_C = (IDM_LANG + 2),
933 | IDM_LANG_CPP = (IDM_LANG + 3),
934 | IDM_LANG_JAVA = (IDM_LANG + 4),
935 | IDM_LANG_HTML = (IDM_LANG + 5),
936 | IDM_LANG_XML = (IDM_LANG + 6),
937 | IDM_LANG_JS = (IDM_LANG + 7),
938 | IDM_LANG_PHP = (IDM_LANG + 8),
939 | IDM_LANG_ASP = (IDM_LANG + 9),
940 | IDM_LANG_CSS = (IDM_LANG + 10),
941 | IDM_LANG_PASCAL = (IDM_LANG + 11),
942 | IDM_LANG_PYTHON = (IDM_LANG + 12),
943 | IDM_LANG_PERL = (IDM_LANG + 13),
944 | IDM_LANG_OBJC = (IDM_LANG + 14),
945 | IDM_LANG_ASCII = (IDM_LANG + 15),
946 | IDM_LANG_TEXT = (IDM_LANG + 16),
947 | IDM_LANG_RC = (IDM_LANG + 17),
948 | IDM_LANG_MAKEFILE = (IDM_LANG + 18),
949 | IDM_LANG_INI = (IDM_LANG + 19),
950 | IDM_LANG_SQL = (IDM_LANG + 20),
951 | IDM_LANG_VB = (IDM_LANG + 21),
952 | IDM_LANG_BATCH = (IDM_LANG + 22),
953 | IDM_LANG_CS = (IDM_LANG + 23),
954 | IDM_LANG_LUA = (IDM_LANG + 24),
955 | IDM_LANG_TEX = (IDM_LANG + 25),
956 | IDM_LANG_FORTRAN = (IDM_LANG + 26),
957 | IDM_LANG_BASH = (IDM_LANG + 27),
958 | IDM_LANG_FLASH = (IDM_LANG + 28),
959 | IDM_LANG_NSIS = (IDM_LANG + 29),
960 | IDM_LANG_TCL = (IDM_LANG + 30),
961 | IDM_LANG_LISP = (IDM_LANG + 31),
962 | IDM_LANG_SCHEME = (IDM_LANG + 32),
963 | IDM_LANG_ASM = (IDM_LANG + 33),
964 | IDM_LANG_DIFF = (IDM_LANG + 34),
965 | IDM_LANG_PROPS = (IDM_LANG + 35),
966 | IDM_LANG_PS = (IDM_LANG + 36),
967 | IDM_LANG_RUBY = (IDM_LANG + 37),
968 | IDM_LANG_SMALLTALK = (IDM_LANG + 38),
969 | IDM_LANG_VHDL = (IDM_LANG + 39),
970 | IDM_LANG_CAML = (IDM_LANG + 40),
971 | IDM_LANG_KIX = (IDM_LANG + 41),
972 | IDM_LANG_ADA = (IDM_LANG + 42),
973 | IDM_LANG_VERILOG = (IDM_LANG + 43),
974 | IDM_LANG_AU3 = (IDM_LANG + 44),
975 | IDM_LANG_MATLAB = (IDM_LANG + 45),
976 | IDM_LANG_HASKELL = (IDM_LANG + 46),
977 | IDM_LANG_INNO = (IDM_LANG + 47),
978 | IDM_LANG_CMAKE = (IDM_LANG + 48),
979 | IDM_LANG_YAML = (IDM_LANG + 49),
980 | IDM_LANG_COBOL = (IDM_LANG + 50),
981 | IDM_LANG_D = (IDM_LANG + 51),
982 | IDM_LANG_GUI4CLI = (IDM_LANG + 52),
983 | IDM_LANG_POWERSHELL = (IDM_LANG + 53),
984 | IDM_LANG_R = (IDM_LANG + 54),
985 | IDM_LANG_JSP = (IDM_LANG + 55),
986 |
987 | IDM_LANG_EXTERNAL = (IDM_LANG + 65),
988 | IDM_LANG_EXTERNAL_LIMIT = (IDM_LANG + 79),
989 |
990 | IDM_LANG_USER = (IDM_LANG + 80), //46080
991 | IDM_LANG_USER_LIMIT = (IDM_LANG + 110), //46110
992 |
993 |
994 | IDM_ABOUT = (IDM + 7000),
995 | IDM_HOMESWEETHOME = (IDM_ABOUT + 1),
996 | IDM_PROJECTPAGE = (IDM_ABOUT + 2),
997 | IDM_ONLINEHELP = (IDM_ABOUT + 3),
998 | IDM_FORUM = (IDM_ABOUT + 4),
999 | IDM_PLUGINSHOME = (IDM_ABOUT + 5),
1000 | IDM_UPDATE_NPP = (IDM_ABOUT + 6),
1001 | IDM_WIKIFAQ = (IDM_ABOUT + 7),
1002 | IDM_HELP = (IDM_ABOUT + 8),
1003 |
1004 |
1005 | IDM_SETTING = (IDM + 8000),
1006 | IDM_SETTING_TAB_SIZE = (IDM_SETTING + 1),
1007 | IDM_SETTING_TAB_REPLCESPACE = (IDM_SETTING + 2),
1008 | IDM_SETTING_HISTORY_SIZE = (IDM_SETTING + 3),
1009 | IDM_SETTING_EDGE_SIZE = (IDM_SETTING + 4),
1010 | IDM_SETTING_IMPORTPLUGIN = (IDM_SETTING + 5),
1011 | IDM_SETTING_IMPORTSTYLETHEMS = (IDM_SETTING + 6),
1012 | IDM_SETTING_TRAYICON = (IDM_SETTING + 8),
1013 | IDM_SETTING_SHORTCUT_MAPPER = (IDM_SETTING + 9),
1014 | IDM_SETTING_REMEMBER_LAST_SESSION = (IDM_SETTING + 10),
1015 | IDM_SETTING_PREFERECE = (IDM_SETTING + 11),
1016 | IDM_SETTING_AUTOCNBCHAR = (IDM_SETTING + 15),
1017 | IDM_SETTING_SHORTCUT_MAPPER_MACRO = (IDM_SETTING + 16),
1018 | IDM_SETTING_SHORTCUT_MAPPER_RUN = (IDM_SETTING + 17),
1019 | IDM_SETTING_EDITCONTEXTMENU = (IDM_SETTING + 18),
1020 |
1021 | IDM_EXECUTE = (IDM + 9000),
1022 |
1023 | IDM_SYSTRAYPOPUP = (IDM + 3100),
1024 | IDM_SYSTRAYPOPUP_ACTIVATE = (IDM_SYSTRAYPOPUP + 1),
1025 | IDM_SYSTRAYPOPUP_NEWDOC = (IDM_SYSTRAYPOPUP + 2),
1026 | IDM_SYSTRAYPOPUP_NEW_AND_PASTE = (IDM_SYSTRAYPOPUP + 3),
1027 | IDM_SYSTRAYPOPUP_OPENFILE = (IDM_SYSTRAYPOPUP + 4),
1028 | IDM_SYSTRAYPOPUP_CLOSE = (IDM_SYSTRAYPOPUP + 5)
1029 | }
1030 |
1031 | [Flags]
1032 | public enum DockMgrMsg : uint
1033 | {
1034 | IDB_CLOSE_DOWN = 137,
1035 | IDB_CLOSE_UP = 138,
1036 | IDD_CONTAINER_DLG = 139,
1037 |
1038 | IDC_TAB_CONT = 1027,
1039 | IDC_CLIENT_TAB = 1028,
1040 | IDC_BTN_CAPTION = 1050,
1041 |
1042 | DMM_MSG = 0x5000,
1043 | DMM_CLOSE = (DMM_MSG + 1),
1044 | DMM_DOCK = (DMM_MSG + 2),
1045 | DMM_FLOAT = (DMM_MSG + 3),
1046 | DMM_DOCKALL = (DMM_MSG + 4),
1047 | DMM_FLOATALL = (DMM_MSG + 5),
1048 | DMM_MOVE = (DMM_MSG + 6),
1049 | DMM_UPDATEDISPINFO = (DMM_MSG + 7),
1050 | DMM_GETIMAGELIST = (DMM_MSG + 8),
1051 | DMM_GETICONPOS = (DMM_MSG + 9),
1052 | DMM_DROPDATA = (DMM_MSG + 10),
1053 | DMM_MOVE_SPLITTER = (DMM_MSG + 11),
1054 | DMM_CANCEL_MOVE = (DMM_MSG + 12),
1055 | DMM_LBUTTONUP = (DMM_MSG + 13),
1056 |
1057 | DMN_FIRST = 1050,
1058 | DMN_CLOSE = (DMN_FIRST + 1),
1059 | //nmhdr.code = DWORD(DMN_CLOSE, 0));
1060 | //nmhdr.hwndFrom = hwndNpp;
1061 | //nmhdr.idFrom = ctrlIdNpp;
1062 |
1063 | DMN_DOCK = (DMN_FIRST + 2),
1064 | DMN_FLOAT = (DMN_FIRST + 3)
1065 | //nmhdr.code = DWORD(DMN_XXX, int newContainer);
1066 | //nmhdr.hwndFrom = hwndNpp;
1067 | //nmhdr.idFrom = ctrlIdNpp;
1068 | }
1069 |
1070 | [StructLayout(LayoutKind.Sequential)]
1071 | public struct toolbarIcons
1072 | {
1073 | public IntPtr hToolbarBmp;
1074 | public IntPtr hToolbarIcon;
1075 | }
1076 | #endregion
1077 |
1078 | #region " Scintilla "
1079 | [StructLayout(LayoutKind.Sequential)]
1080 | public struct Sci_NotifyHeader
1081 | {
1082 | /* Compatible with Windows NMHDR.
1083 | * hwndFrom is really an environment specific window handle or pointer
1084 | * but most clients of Scintilla.h do not have this type visible. */
1085 | public IntPtr hwndFrom;
1086 | public IntPtr idFrom;
1087 | public uint code;
1088 | }
1089 |
1090 | [StructLayout(LayoutKind.Sequential)]
1091 | public struct SCNotification
1092 | {
1093 | public Sci_NotifyHeader nmhdr;
1094 | public int position; /* SCN_STYLENEEDED, SCN_MODIFIED, SCN_DWELLSTART, SCN_DWELLEND */
1095 | public int ch; /* SCN_CHARADDED, SCN_KEY */
1096 | public int modifiers; /* SCN_KEY */
1097 | public int modificationType; /* SCN_MODIFIED */
1098 | public IntPtr text; /* SCN_MODIFIED, SCN_USERLISTSELECTION, SCN_AUTOCSELECTION */
1099 | public int length; /* SCN_MODIFIED */
1100 | public int linesAdded; /* SCN_MODIFIED */
1101 | public int message; /* SCN_MACRORECORD */
1102 | public IntPtr wParam; /* SCN_MACRORECORD */
1103 | public IntPtr lParam; /* SCN_MACRORECORD */
1104 | public int line; /* SCN_MODIFIED */
1105 | public int foldLevelNow; /* SCN_MODIFIED */
1106 | public int foldLevelPrev; /* SCN_MODIFIED */
1107 | public int margin; /* SCN_MARGINCLICK */
1108 | public int listType; /* SCN_USERLISTSELECTION */
1109 | public int x; /* SCN_DWELLSTART, SCN_DWELLEND */
1110 | public int y; /* SCN_DWELLSTART, SCN_DWELLEND */
1111 | public int token; /* SCN_MODIFIED with SC_MOD_CONTAINER */
1112 | public int annotationLinesAdded;/* SC_MOD_CHANGEANNOTATION */
1113 | }
1114 |
1115 | [Flags]
1116 | public enum SciMsg : uint
1117 | {
1118 | INVALID_POSITION = 0xFFFFFFFF,
1119 | SCI_START = 2000,
1120 | SCI_OPTIONAL_START = 3000,
1121 | SCI_LEXER_START = 4000,
1122 | SCI_ADDTEXT = 2001,
1123 | SCI_ADDSTYLEDTEXT = 2002,
1124 | SCI_INSERTTEXT = 2003,
1125 | SCI_CLEARALL = 2004,
1126 | SCI_CLEARDOCUMENTSTYLE = 2005,
1127 | SCI_GETLENGTH = 2006,
1128 | SCI_GETCHARAT = 2007,
1129 | SCI_GETCURRENTPOS = 2008,
1130 | SCI_GETANCHOR = 2009,
1131 | SCI_GETSTYLEAT = 2010,
1132 | SCI_REDO = 2011,
1133 | SCI_SETUNDOCOLLECTION = 2012,
1134 | SCI_SELECTALL = 2013,
1135 | SCI_SETSAVEPOINT = 2014,
1136 | SCI_GETSTYLEDTEXT = 2015,
1137 | SCI_CANREDO = 2016,
1138 | SCI_MARKERLINEFROMHANDLE = 2017,
1139 | SCI_MARKERDELETEHANDLE = 2018,
1140 | SCI_GETUNDOCOLLECTION = 2019,
1141 | SCWS_INVISIBLE = 0,
1142 | SCWS_VISIBLEALWAYS = 1,
1143 | SCWS_VISIBLEAFTERINDENT = 2,
1144 | SCI_GETVIEWWS = 2020,
1145 | SCI_SETVIEWWS = 2021,
1146 | SCI_POSITIONFROMPOINT = 2022,
1147 | SCI_POSITIONFROMPOINTCLOSE = 2023,
1148 | SCI_GOTOLINE = 2024,
1149 | SCI_GOTOPOS = 2025,
1150 | SCI_SETANCHOR = 2026,
1151 | SCI_GETCURLINE = 2027,
1152 | SCI_GETENDSTYLED = 2028,
1153 | SC_EOL_CRLF = 0,
1154 | SC_EOL_CR = 1,
1155 | SC_EOL_LF = 2,
1156 | SCI_CONVERTEOLS = 2029,
1157 | SCI_GETEOLMODE = 2030,
1158 | SCI_SETEOLMODE = 2031,
1159 | SCI_STARTSTYLING = 2032,
1160 | SCI_SETSTYLING = 2033,
1161 | SCI_GETBUFFEREDDRAW = 2034,
1162 | SCI_SETBUFFEREDDRAW = 2035,
1163 | SCI_SETTABWIDTH = 2036,
1164 | SCI_GETTABWIDTH = 2121,
1165 | SC_CP_UTF8 = 65001,
1166 | SC_CP_DBCS = 1,
1167 | SCI_SETCODEPAGE = 2037,
1168 | SCI_SETUSEPALETTE = 2039,
1169 | MARKER_MAX = 31,
1170 | SC_MARK_CIRCLE = 0,
1171 | SC_MARK_ROUNDRECT = 1,
1172 | SC_MARK_ARROW = 2,
1173 | SC_MARK_SMALLRECT = 3,
1174 | SC_MARK_SHORTARROW = 4,
1175 | SC_MARK_EMPTY = 5,
1176 | SC_MARK_ARROWDOWN = 6,
1177 | SC_MARK_MINUS = 7,
1178 | SC_MARK_PLUS = 8,
1179 | SC_MARK_VLINE = 9,
1180 | SC_MARK_LCORNER = 10,
1181 | SC_MARK_TCORNER = 11,
1182 | SC_MARK_BOXPLUS = 12,
1183 | SC_MARK_BOXPLUSCONNECTED = 13,
1184 | SC_MARK_BOXMINUS = 14,
1185 | SC_MARK_BOXMINUSCONNECTED = 15,
1186 | SC_MARK_LCORNERCURVE = 16,
1187 | SC_MARK_TCORNERCURVE = 17,
1188 | SC_MARK_CIRCLEPLUS = 18,
1189 | SC_MARK_CIRCLEPLUSCONNECTED = 19,
1190 | SC_MARK_CIRCLEMINUS = 20,
1191 | SC_MARK_CIRCLEMINUSCONNECTED = 21,
1192 | SC_MARK_BACKGROUND = 22,
1193 | SC_MARK_DOTDOTDOT = 23,
1194 | SC_MARK_ARROWS = 24,
1195 | SC_MARK_PIXMAP = 25,
1196 | SC_MARK_FULLRECT = 26,
1197 | SC_MARK_LEFTRECT = 27,
1198 | SC_MARK_AVAILABLE = 28,
1199 | SC_MARK_UNDERLINE = 29,
1200 | SC_MARK_CHARACTER = 10000,
1201 | SC_MARKNUM_FOLDEREND = 25,
1202 | SC_MARKNUM_FOLDEROPENMID = 26,
1203 | SC_MARKNUM_FOLDERMIDTAIL = 27,
1204 | SC_MARKNUM_FOLDERTAIL = 28,
1205 | SC_MARKNUM_FOLDERSUB = 29,
1206 | SC_MARKNUM_FOLDER = 30,
1207 | SC_MARKNUM_FOLDEROPEN = 31,
1208 | SC_MASK_FOLDERS = 0xFE000000,
1209 | SCI_MARKERDEFINE = 2040,
1210 | SCI_MARKERSETFORE = 2041,
1211 | SCI_MARKERSETBACK = 2042,
1212 | SCI_MARKERADD = 2043,
1213 | SCI_MARKERDELETE = 2044,
1214 | SCI_MARKERDELETEALL = 2045,
1215 | SCI_MARKERGET = 2046,
1216 | SCI_MARKERNEXT = 2047,
1217 | SCI_MARKERPREVIOUS = 2048,
1218 | SCI_MARKERDEFINEPIXMAP = 2049,
1219 | SCI_MARKERADDSET = 2466,
1220 | SCI_MARKERSETALPHA = 2476,
1221 | SC_MARGIN_SYMBOL = 0,
1222 | SC_MARGIN_NUMBER = 1,
1223 | SC_MARGIN_BACK = 2,
1224 | SC_MARGIN_FORE = 3,
1225 | SC_MARGIN_TEXT = 4,
1226 | SC_MARGIN_RTEXT = 5,
1227 | SCI_SETMARGINTYPEN = 2240,
1228 | SCI_GETMARGINTYPEN = 2241,
1229 | SCI_SETMARGINWIDTHN = 2242,
1230 | SCI_GETMARGINWIDTHN = 2243,
1231 | SCI_SETMARGINMASKN = 2244,
1232 | SCI_GETMARGINMASKN = 2245,
1233 | SCI_SETMARGINSENSITIVEN = 2246,
1234 | SCI_GETMARGINSENSITIVEN = 2247,
1235 | STYLE_DEFAULT = 32,
1236 | STYLE_LINENUMBER = 33,
1237 | STYLE_BRACELIGHT = 34,
1238 | STYLE_BRACEBAD = 35,
1239 | STYLE_CONTROLCHAR = 36,
1240 | STYLE_INDENTGUIDE = 37,
1241 | STYLE_CALLTIP = 38,
1242 | STYLE_LASTPREDEFINED = 39,
1243 | STYLE_MAX = 255,
1244 | SC_CHARSET_ANSI = 0,
1245 | SC_CHARSET_DEFAULT = 1,
1246 | SC_CHARSET_BALTIC = 186,
1247 | SC_CHARSET_CHINESEBIG5 = 136,
1248 | SC_CHARSET_EASTEUROPE = 238,
1249 | SC_CHARSET_GB2312 = 134,
1250 | SC_CHARSET_GREEK = 161,
1251 | SC_CHARSET_HANGUL = 129,
1252 | SC_CHARSET_MAC = 77,
1253 | SC_CHARSET_OEM = 255,
1254 | SC_CHARSET_RUSSIAN = 204,
1255 | SC_CHARSET_CYRILLIC = 1251,
1256 | SC_CHARSET_SHIFTJIS = 128,
1257 | SC_CHARSET_SYMBOL = 2,
1258 | SC_CHARSET_TURKISH = 162,
1259 | SC_CHARSET_JOHAB = 130,
1260 | SC_CHARSET_HEBREW = 177,
1261 | SC_CHARSET_ARABIC = 178,
1262 | SC_CHARSET_VIETNAMESE = 163,
1263 | SC_CHARSET_THAI = 222,
1264 | SC_CHARSET_8859_15 = 1000,
1265 | SCI_STYLECLEARALL = 2050,
1266 | SCI_STYLESETFORE = 2051,
1267 | SCI_STYLESETBACK = 2052,
1268 | SCI_STYLESETBOLD = 2053,
1269 | SCI_STYLESETITALIC = 2054,
1270 | SCI_STYLESETSIZE = 2055,
1271 | SCI_STYLESETFONT = 2056,
1272 | SCI_STYLESETEOLFILLED = 2057,
1273 | SCI_STYLERESETDEFAULT = 2058,
1274 | SCI_STYLESETUNDERLINE = 2059,
1275 | SC_CASE_MIXED = 0,
1276 | SC_CASE_UPPER = 1,
1277 | SC_CASE_LOWER = 2,
1278 | SCI_STYLEGETFORE = 2481,
1279 | SCI_STYLEGETBACK = 2482,
1280 | SCI_STYLEGETBOLD = 2483,
1281 | SCI_STYLEGETITALIC = 2484,
1282 | SCI_STYLEGETSIZE = 2485,
1283 | SCI_STYLEGETFONT = 2486,
1284 | SCI_STYLEGETEOLFILLED = 2487,
1285 | SCI_STYLEGETUNDERLINE = 2488,
1286 | SCI_STYLEGETCASE = 2489,
1287 | SCI_STYLEGETCHARACTERSET = 2490,
1288 | SCI_STYLEGETVISIBLE = 2491,
1289 | SCI_STYLEGETCHANGEABLE = 2492,
1290 | SCI_STYLEGETHOTSPOT = 2493,
1291 | SCI_STYLESETCASE = 2060,
1292 | SCI_STYLESETCHARACTERSET = 2066,
1293 | SCI_STYLESETHOTSPOT = 2409,
1294 | SCI_SETSELFORE = 2067,
1295 | SCI_SETSELBACK = 2068,
1296 | SCI_GETSELALPHA = 2477,
1297 | SCI_SETSELALPHA = 2478,
1298 | SCI_GETSELEOLFILLED = 2479,
1299 | SCI_SETSELEOLFILLED = 2480,
1300 | SCI_SETCARETFORE = 2069,
1301 | SCI_ASSIGNCMDKEY = 2070,
1302 | SCI_CLEARCMDKEY = 2071,
1303 | SCI_CLEARALLCMDKEYS = 2072,
1304 | SCI_SETSTYLINGEX = 2073,
1305 | SCI_STYLESETVISIBLE = 2074,
1306 | SCI_GETCARETPERIOD = 2075,
1307 | SCI_SETCARETPERIOD = 2076,
1308 | SCI_SETWORDCHARS = 2077,
1309 | SCI_BEGINUNDOACTION = 2078,
1310 | SCI_ENDUNDOACTION = 2079,
1311 | INDIC_PLAIN = 0,
1312 | INDIC_SQUIGGLE = 1,
1313 | INDIC_TT = 2,
1314 | INDIC_DIAGONAL = 3,
1315 | INDIC_STRIKE = 4,
1316 | INDIC_HIDDEN = 5,
1317 | INDIC_BOX = 6,
1318 | INDIC_ROUNDBOX = 7,
1319 | INDIC_MAX = 31,
1320 | INDIC_CONTAINER = 8,
1321 | INDIC0_MASK = 0x20,
1322 | INDIC1_MASK = 0x40,
1323 | INDIC2_MASK = 0x80,
1324 | INDICS_MASK = 0xE0,
1325 | SCI_INDICSETSTYLE = 2080,
1326 | SCI_INDICGETSTYLE = 2081,
1327 | SCI_INDICSETFORE = 2082,
1328 | SCI_INDICGETFORE = 2083,
1329 | SCI_INDICSETUNDER = 2510,
1330 | SCI_INDICGETUNDER = 2511,
1331 | SCI_GETCARETLINEVISIBLEALWAYS = 3095,
1332 | SCI_SETCARETLINEVISIBLEALWAYS = 3096,
1333 | SCI_SETWHITESPACEFORE = 2084,
1334 | SCI_SETWHITESPACEBACK = 2085,
1335 | SCI_SETSTYLEBITS = 2090,
1336 | SCI_GETSTYLEBITS = 2091,
1337 | SCI_SETLINESTATE = 2092,
1338 | SCI_GETLINESTATE = 2093,
1339 | SCI_GETMAXLINESTATE = 2094,
1340 | SCI_GETCARETLINEVISIBLE = 2095,
1341 | SCI_SETCARETLINEVISIBLE = 2096,
1342 | SCI_GETCARETLINEBACK = 2097,
1343 | SCI_SETCARETLINEBACK = 2098,
1344 | SCI_STYLESETCHANGEABLE = 2099,
1345 | SCI_AUTOCSHOW = 2100,
1346 | SCI_AUTOCCANCEL = 2101,
1347 | SCI_AUTOCACTIVE = 2102,
1348 | SCI_AUTOCPOSSTART = 2103,
1349 | SCI_AUTOCCOMPLETE = 2104,
1350 | SCI_AUTOCSTOPS = 2105,
1351 | SCI_AUTOCSETSEPARATOR = 2106,
1352 | SCI_AUTOCGETSEPARATOR = 2107,
1353 | SCI_AUTOCSELECT = 2108,
1354 | SCI_AUTOCSETCANCELATSTART = 2110,
1355 | SCI_AUTOCGETCANCELATSTART = 2111,
1356 | SCI_AUTOCSETFILLUPS = 2112,
1357 | SCI_AUTOCSETCHOOSESINGLE = 2113,
1358 | SCI_AUTOCGETCHOOSESINGLE = 2114,
1359 | SCI_AUTOCSETIGNORECASE = 2115,
1360 | SCI_AUTOCGETIGNORECASE = 2116,
1361 | SCI_USERLISTSHOW = 2117,
1362 | SCI_AUTOCSETAUTOHIDE = 2118,
1363 | SCI_AUTOCGETAUTOHIDE = 2119,
1364 | SCI_AUTOCSETDROPRESTOFWORD = 2270,
1365 | SCI_AUTOCGETDROPRESTOFWORD = 2271,
1366 | SCI_REGISTERIMAGE = 2405,
1367 | SCI_CLEARREGISTEREDIMAGES = 2408,
1368 | SCI_AUTOCGETTYPESEPARATOR = 2285,
1369 | SCI_AUTOCSETTYPESEPARATOR = 2286,
1370 | SCI_AUTOCSETMAXWIDTH = 2208,
1371 | SCI_AUTOCGETMAXWIDTH = 2209,
1372 | SCI_AUTOCSETMAXHEIGHT = 2210,
1373 | SCI_AUTOCGETMAXHEIGHT = 2211,
1374 | SCI_SETINDENT = 2122,
1375 | SCI_GETINDENT = 2123,
1376 | SCI_SETUSETABS = 2124,
1377 | SCI_GETUSETABS = 2125,
1378 | SCI_SETLINEINDENTATION = 2126,
1379 | SCI_GETLINEINDENTATION = 2127,
1380 | SCI_GETLINEINDENTPOSITION = 2128,
1381 | SCI_GETCOLUMN = 2129,
1382 | SCI_SETHSCROLLBAR = 2130,
1383 | SCI_GETHSCROLLBAR = 2131,
1384 | SC_IV_NONE = 0,
1385 | SC_IV_REAL = 1,
1386 | SC_IV_LOOKFORWARD = 2,
1387 | SC_IV_LOOKBOTH = 3,
1388 | SCI_SETINDENTATIONGUIDES = 2132,
1389 | SCI_GETINDENTATIONGUIDES = 2133,
1390 | SCI_SETHIGHLIGHTGUIDE = 2134,
1391 | SCI_GETHIGHLIGHTGUIDE = 2135,
1392 | SCI_GETLINEENDPOSITION = 2136,
1393 | SCI_GETCODEPAGE = 2137,
1394 | SCI_GETCARETFORE = 2138,
1395 | SCI_GETUSEPALETTE = 2139,
1396 | SCI_GETREADONLY = 2140,
1397 | SCI_SETCURRENTPOS = 2141,
1398 | SCI_SETSELECTIONSTART = 2142,
1399 | SCI_GETSELECTIONSTART = 2143,
1400 | SCI_SETSELECTIONEND = 2144,
1401 | SCI_GETSELECTIONEND = 2145,
1402 | SCI_SETPRINTMAGNIFICATION = 2146,
1403 | SCI_GETPRINTMAGNIFICATION = 2147,
1404 | SC_PRINT_NORMAL = 0,
1405 | SC_PRINT_INVERTLIGHT = 1,
1406 | SC_PRINT_BLACKONWHITE = 2,
1407 | SC_PRINT_COLOURONWHITE = 3,
1408 | SC_PRINT_COLOURONWHITEDEFAULTBG = 4,
1409 | SCI_SETPRINTCOLOURMODE = 2148,
1410 | SCI_GETPRINTCOLOURMODE = 2149,
1411 | SCFIND_WHOLEWORD = 2,
1412 | SCFIND_MATCHCASE = 4,
1413 | SCFIND_WORDSTART = 0x00100000,
1414 | SCFIND_REGEXP = 0x00200000,
1415 | SCFIND_POSIX = 0x00400000,
1416 | SCI_FINDTEXT = 2150,
1417 | SCI_FORMATRANGE = 2151,
1418 | SCI_GETFIRSTVISIBLELINE = 2152,
1419 | SCI_GETLINE = 2153,
1420 | SCI_GETLINECOUNT = 2154,
1421 | SCI_SETMARGINLEFT = 2155,
1422 | SCI_GETMARGINLEFT = 2156,
1423 | SCI_SETMARGINRIGHT = 2157,
1424 | SCI_GETMARGINRIGHT = 2158,
1425 | SCI_GETMODIFY = 2159,
1426 | SCI_SETSEL = 2160,
1427 | SCI_GETSELTEXT = 2161,
1428 | SCI_GETTEXTRANGE = 2162,
1429 | SCI_HIDESELECTION = 2163,
1430 | SCI_POINTXFROMPOSITION = 2164,
1431 | SCI_POINTYFROMPOSITION = 2165,
1432 | SCI_LINEFROMPOSITION = 2166,
1433 | SCI_POSITIONFROMLINE = 2167,
1434 | SCI_LINESCROLL = 2168,
1435 | SCI_SCROLLCARET = 2169,
1436 | SCI_REPLACESEL = 2170,
1437 | SCI_SETREADONLY = 2171,
1438 | SCI_NULL = 2172,
1439 | SCI_CANPASTE = 2173,
1440 | SCI_CANUNDO = 2174,
1441 | SCI_EMPTYUNDOBUFFER = 2175,
1442 | SCI_UNDO = 2176,
1443 | SCI_CUT = 2177,
1444 | SCI_COPY = 2178,
1445 | SCI_PASTE = 2179,
1446 | SCI_CLEAR = 2180,
1447 | SCI_SETTEXT = 2181,
1448 | SCI_GETTEXT = 2182,
1449 | SCI_GETTEXTLENGTH = 2183,
1450 | SCI_GETDIRECTFUNCTION = 2184,
1451 | SCI_GETDIRECTPOINTER = 2185,
1452 | SCI_SETOVERTYPE = 2186,
1453 | SCI_GETOVERTYPE = 2187,
1454 | SCI_SETCARETWIDTH = 2188,
1455 | SCI_GETCARETWIDTH = 2189,
1456 | SCI_SETTARGETSTART = 2190,
1457 | SCI_GETTARGETSTART = 2191,
1458 | SCI_SETTARGETEND = 2192,
1459 | SCI_GETTARGETEND = 2193,
1460 | SCI_REPLACETARGET = 2194,
1461 | SCI_REPLACETARGETRE = 2195,
1462 | SCI_SEARCHINTARGET = 2197,
1463 | SCI_SETSEARCHFLAGS = 2198,
1464 | SCI_GETSEARCHFLAGS = 2199,
1465 | SCI_CALLTIPSHOW = 2200,
1466 | SCI_CALLTIPCANCEL = 2201,
1467 | SCI_CALLTIPACTIVE = 2202,
1468 | SCI_CALLTIPPOSSTART = 2203,
1469 | SCI_CALLTIPSETHLT = 2204,
1470 | SCI_CALLTIPSETBACK = 2205,
1471 | SCI_CALLTIPSETFORE = 2206,
1472 | SCI_CALLTIPSETFOREHLT = 2207,
1473 | SCI_CALLTIPUSESTYLE = 2212,
1474 | SCI_VISIBLEFROMDOCLINE = 2220,
1475 | SCI_DOCLINEFROMVISIBLE = 2221,
1476 | SCI_WRAPCOUNT = 2235,
1477 | SC_FOLDLEVELBASE = 0x400,
1478 | SC_FOLDLEVELWHITEFLAG = 0x1000,
1479 | SC_FOLDLEVELHEADERFLAG = 0x2000,
1480 | SC_FOLDLEVELNUMBERMASK = 0x0FFF,
1481 | SCI_SETFOLDLEVEL = 2222,
1482 | SCI_GETFOLDLEVEL = 2223,
1483 | SCI_GETLASTCHILD = 2224,
1484 | SCI_GETFOLDPARENT = 2225,
1485 | SCI_SHOWLINES = 2226,
1486 | SCI_HIDELINES = 2227,
1487 | SCI_GETLINEVISIBLE = 2228,
1488 | SCI_SETFOLDEXPANDED = 2229,
1489 | SCI_GETFOLDEXPANDED = 2230,
1490 | SCI_TOGGLEFOLD = 2231,
1491 | SCI_ENSUREVISIBLE = 2232,
1492 | SC_FOLDFLAG_LINEBEFORE_EXPANDED = 0x0002,
1493 | SC_FOLDFLAG_LINEBEFORE_CONTRACTED = 0x0004,
1494 | SC_FOLDFLAG_LINEAFTER_EXPANDED = 0x0008,
1495 | SC_FOLDFLAG_LINEAFTER_CONTRACTED = 0x0010,
1496 | SC_FOLDFLAG_LEVELNUMBERS = 0x0040,
1497 | SCI_SETFOLDFLAGS = 2233,
1498 | SCI_ENSUREVISIBLEENFORCEPOLICY = 2234,
1499 | SCI_SETTABINDENTS = 2260,
1500 | SCI_GETTABINDENTS = 2261,
1501 | SCI_SETBACKSPACEUNINDENTS = 2262,
1502 | SCI_GETBACKSPACEUNINDENTS = 2263,
1503 | SC_TIME_FOREVER = 10000000,
1504 | SCI_SETMOUSEDWELLTIME = 2264,
1505 | SCI_GETMOUSEDWELLTIME = 2265,
1506 | SCI_WORDSTARTPOSITION = 2266,
1507 | SCI_WORDENDPOSITION = 2267,
1508 | SC_WRAP_NONE = 0,
1509 | SC_WRAP_WORD = 1,
1510 | SC_WRAP_CHAR = 2,
1511 | SCI_SETWRAPMODE = 2268,
1512 | SCI_GETWRAPMODE = 2269,
1513 | SC_WRAPVISUALFLAG_NONE = 0x0000,
1514 | SC_WRAPVISUALFLAG_END = 0x0001,
1515 | SC_WRAPVISUALFLAG_START = 0x0002,
1516 | SCI_SETWRAPVISUALFLAGS = 2460,
1517 | SCI_GETWRAPVISUALFLAGS = 2461,
1518 | SC_WRAPVISUALFLAGLOC_DEFAULT = 0x0000,
1519 | SC_WRAPVISUALFLAGLOC_END_BY_TEXT = 0x0001,
1520 | SC_WRAPVISUALFLAGLOC_START_BY_TEXT = 0x0002,
1521 | SCI_SETWRAPVISUALFLAGSLOCATION = 2462,
1522 | SCI_GETWRAPVISUALFLAGSLOCATION = 2463,
1523 | SCI_SETWRAPSTARTINDENT = 2464,
1524 | SCI_GETWRAPSTARTINDENT = 2465,
1525 | SC_WRAPINDENT_FIXED = 0,
1526 | SC_WRAPINDENT_SAME = 1,
1527 | SC_WRAPINDENT_INDENT = 2,
1528 | SCI_SETWRAPINDENTMODE = 2472,
1529 | SCI_GETWRAPINDENTMODE = 2473,
1530 | SC_CACHE_NONE = 0,
1531 | SC_CACHE_CARET = 1,
1532 | SC_CACHE_PAGE = 2,
1533 | SC_CACHE_DOCUMENT = 3,
1534 | SCI_SETLAYOUTCACHE = 2272,
1535 | SCI_GETLAYOUTCACHE = 2273,
1536 | SCI_SETSCROLLWIDTH = 2274,
1537 | SCI_GETSCROLLWIDTH = 2275,
1538 | SCI_SETSCROLLWIDTHTRACKING = 2516,
1539 | SCI_GETSCROLLWIDTHTRACKING = 2517,
1540 | SCI_TEXTWIDTH = 2276,
1541 | SCI_SETENDATLASTLINE = 2277,
1542 | SCI_GETENDATLASTLINE = 2278,
1543 | SCI_TEXTHEIGHT = 2279,
1544 | SCI_SETVSCROLLBAR = 2280,
1545 | SCI_GETVSCROLLBAR = 2281,
1546 | SCI_APPENDTEXT = 2282,
1547 | SCI_GETTWOPHASEDRAW = 2283,
1548 | SCI_SETTWOPHASEDRAW = 2284,
1549 | SCI_TARGETFROMSELECTION = 2287,
1550 | SCI_LINESJOIN = 2288,
1551 | SCI_LINESSPLIT = 2289,
1552 | SCI_SETFOLDMARGINCOLOUR = 2290,
1553 | SCI_SETFOLDMARGINHICOLOUR = 2291,
1554 | SCI_LINEDOWN = 2300,
1555 | SCI_LINEDOWNEXTEND = 2301,
1556 | SCI_LINEUP = 2302,
1557 | SCI_LINEUPEXTEND = 2303,
1558 | SCI_CHARLEFT = 2304,
1559 | SCI_CHARLEFTEXTEND = 2305,
1560 | SCI_CHARRIGHT = 2306,
1561 | SCI_CHARRIGHTEXTEND = 2307,
1562 | SCI_WORDLEFT = 2308,
1563 | SCI_WORDLEFTEXTEND = 2309,
1564 | SCI_WORDRIGHT = 2310,
1565 | SCI_WORDRIGHTEXTEND = 2311,
1566 | SCI_HOME = 2312,
1567 | SCI_HOMEEXTEND = 2313,
1568 | SCI_LINEEND = 2314,
1569 | SCI_LINEENDEXTEND = 2315,
1570 | SCI_DOCUMENTSTART = 2316,
1571 | SCI_DOCUMENTSTARTEXTEND = 2317,
1572 | SCI_DOCUMENTEND = 2318,
1573 | SCI_DOCUMENTENDEXTEND = 2319,
1574 | SCI_PAGEUP = 2320,
1575 | SCI_PAGEUPEXTEND = 2321,
1576 | SCI_PAGEDOWN = 2322,
1577 | SCI_PAGEDOWNEXTEND = 2323,
1578 | SCI_EDITTOGGLEOVERTYPE = 2324,
1579 | SCI_CANCEL = 2325,
1580 | SCI_DELETEBACK = 2326,
1581 | SCI_TAB = 2327,
1582 | SCI_BACKTAB = 2328,
1583 | SCI_NEWLINE = 2329,
1584 | SCI_FORMFEED = 2330,
1585 | SCI_VCHOME = 2331,
1586 | SCI_VCHOMEEXTEND = 2332,
1587 | SCI_ZOOMIN = 2333,
1588 | SCI_ZOOMOUT = 2334,
1589 | SCI_DELWORDLEFT = 2335,
1590 | SCI_DELWORDRIGHT = 2336,
1591 | SCI_DELWORDRIGHTEND = 2518,
1592 | SCI_LINECUT = 2337,
1593 | SCI_LINEDELETE = 2338,
1594 | SCI_LINETRANSPOSE = 2339,
1595 | SCI_LINEDUPLICATE = 2404,
1596 | SCI_LOWERCASE = 2340,
1597 | SCI_UPPERCASE = 2341,
1598 | SCI_LINESCROLLDOWN = 2342,
1599 | SCI_LINESCROLLUP = 2343,
1600 | SCI_DELETEBACKNOTLINE = 2344,
1601 | SCI_HOMEDISPLAY = 2345,
1602 | SCI_HOMEDISPLAYEXTEND = 2346,
1603 | SCI_LINEENDDISPLAY = 2347,
1604 | SCI_LINEENDDISPLAYEXTEND = 2348,
1605 | SCI_HOMEWRAP = 2349,
1606 | SCI_HOMEWRAPEXTEND = 2450,
1607 | SCI_LINEENDWRAP = 2451,
1608 | SCI_LINEENDWRAPEXTEND = 2452,
1609 | SCI_VCHOMEWRAP = 2453,
1610 | SCI_VCHOMEWRAPEXTEND = 2454,
1611 | SCI_LINECOPY = 2455,
1612 | SCI_MOVECARETINSIDEVIEW = 2401,
1613 | SCI_LINELENGTH = 2350,
1614 | SCI_BRACEHIGHLIGHT = 2351,
1615 | SCI_BRACEBADLIGHT = 2352,
1616 | SCI_BRACEMATCH = 2353,
1617 | SCI_GETVIEWEOL = 2355,
1618 | SCI_SETVIEWEOL = 2356,
1619 | SCI_GETDOCPOINTER = 2357,
1620 | SCI_SETDOCPOINTER = 2358,
1621 | SCI_SETMODEVENTMASK = 2359,
1622 | EDGE_NONE = 0,
1623 | EDGE_LINE = 1,
1624 | EDGE_BACKGROUND = 2,
1625 | SCI_GETEDGECOLUMN = 2360,
1626 | SCI_SETEDGECOLUMN = 2361,
1627 | SCI_GETEDGEMODE = 2362,
1628 | SCI_SETEDGEMODE = 2363,
1629 | SCI_GETEDGECOLOUR = 2364,
1630 | SCI_SETEDGECOLOUR = 2365,
1631 | SCI_SEARCHANCHOR = 2366,
1632 | SCI_SEARCHNEXT = 2367,
1633 | SCI_SEARCHPREV = 2368,
1634 | SCI_LINESONSCREEN = 2370,
1635 | SCI_USEPOPUP = 2371,
1636 | SCI_SELECTIONISRECTANGLE = 2372,
1637 | SCI_SETZOOM = 2373,
1638 | SCI_GETZOOM = 2374,
1639 | SCI_CREATEDOCUMENT = 2375,
1640 | SCI_ADDREFDOCUMENT = 2376,
1641 | SCI_RELEASEDOCUMENT = 2377,
1642 | SCI_GETMODEVENTMASK = 2378,
1643 | SCI_SETFOCUS = 2380,
1644 | SCI_GETFOCUS = 2381,
1645 | SC_STATUS_OK = 0,
1646 | SC_STATUS_FAILURE = 1,
1647 | SC_STATUS_BADALLOC = 2,
1648 | SCI_SETSTATUS = 2382,
1649 | SCI_GETSTATUS = 2383,
1650 | SCI_SETMOUSEDOWNCAPTURES = 2384,
1651 | SCI_GETMOUSEDOWNCAPTURES = 2385,
1652 | SC_CURSORNORMAL = 0xFFFFFFFF,
1653 | SC_CURSORWAIT = 4,
1654 | SCI_SETCURSOR = 2386,
1655 | SCI_GETCURSOR = 2387,
1656 | SCI_SETCONTROLCHARSYMBOL = 2388,
1657 | SCI_GETCONTROLCHARSYMBOL = 2389,
1658 | SCI_WORDPARTLEFT = 2390,
1659 | SCI_WORDPARTLEFTEXTEND = 2391,
1660 | SCI_WORDPARTRIGHT = 2392,
1661 | SCI_WORDPARTRIGHTEXTEND = 2393,
1662 | VISIBLE_SLOP = 0x01,
1663 | VISIBLE_STRICT = 0x04,
1664 | SCI_SETVISIBLEPOLICY = 2394,
1665 | SCI_DELLINELEFT = 2395,
1666 | SCI_DELLINERIGHT = 2396,
1667 | SCI_SETXOFFSET = 2397,
1668 | SCI_GETXOFFSET = 2398,
1669 | SCI_CHOOSECARETX = 2399,
1670 | SCI_GRABFOCUS = 2400,
1671 | CARET_SLOP = 0x01,
1672 | CARET_STRICT = 0x04,
1673 | CARET_JUMPS = 0x10,
1674 | CARET_EVEN = 0x08,
1675 | SCI_SETXCARETPOLICY = 2402,
1676 | SCI_SETYCARETPOLICY = 2403,
1677 | SCI_SETPRINTWRAPMODE = 2406,
1678 | SCI_GETPRINTWRAPMODE = 2407,
1679 | SCI_SETHOTSPOTACTIVEFORE = 2410,
1680 | SCI_GETHOTSPOTACTIVEFORE = 2494,
1681 | SCI_SETHOTSPOTACTIVEBACK = 2411,
1682 | SCI_GETHOTSPOTACTIVEBACK = 2495,
1683 | SCI_SETHOTSPOTACTIVEUNDERLINE = 2412,
1684 | SCI_GETHOTSPOTACTIVEUNDERLINE = 2496,
1685 | SCI_SETHOTSPOTSINGLELINE = 2421,
1686 | SCI_GETHOTSPOTSINGLELINE = 2497,
1687 | SCI_PARADOWN = 2413,
1688 | SCI_PARADOWNEXTEND = 2414,
1689 | SCI_PARAUP = 2415,
1690 | SCI_PARAUPEXTEND = 2416,
1691 | SCI_POSITIONBEFORE = 2417,
1692 | SCI_POSITIONAFTER = 2418,
1693 | SCI_COPYRANGE = 2419,
1694 | SCI_COPYTEXT = 2420,
1695 | SC_SEL_STREAM = 0,
1696 | SC_SEL_RECTANGLE = 1,
1697 | SC_SEL_LINES = 2,
1698 | SC_SEL_THIN = 3,
1699 | SCI_SETSELECTIONMODE = 2422,
1700 | SCI_GETSELECTIONMODE = 2423,
1701 | SCI_GETLINESELSTARTPOSITION = 2424,
1702 | SCI_GETLINESELENDPOSITION = 2425,
1703 | SCI_LINEDOWNRECTEXTEND = 2426,
1704 | SCI_LINEUPRECTEXTEND = 2427,
1705 | SCI_CHARLEFTRECTEXTEND = 2428,
1706 | SCI_CHARRIGHTRECTEXTEND = 2429,
1707 | SCI_HOMERECTEXTEND = 2430,
1708 | SCI_VCHOMERECTEXTEND = 2431,
1709 | SCI_LINEENDRECTEXTEND = 2432,
1710 | SCI_PAGEUPRECTEXTEND = 2433,
1711 | SCI_PAGEDOWNRECTEXTEND = 2434,
1712 | SCI_STUTTEREDPAGEUP = 2435,
1713 | SCI_STUTTEREDPAGEUPEXTEND = 2436,
1714 | SCI_STUTTEREDPAGEDOWN = 2437,
1715 | SCI_STUTTEREDPAGEDOWNEXTEND = 2438,
1716 | SCI_WORDLEFTEND = 2439,
1717 | SCI_WORDLEFTENDEXTEND = 2440,
1718 | SCI_WORDRIGHTEND = 2441,
1719 | SCI_WORDRIGHTENDEXTEND = 2442,
1720 | SCI_SETWHITESPACECHARS = 2443,
1721 | SCI_SETCHARSDEFAULT = 2444,
1722 | SCI_AUTOCGETCURRENT = 2445,
1723 | SCI_ALLOCATE = 2446,
1724 | SCI_TARGETASUTF8 = 2447,
1725 | SCI_SETLENGTHFORENCODE = 2448,
1726 | SCI_ENCODEDFROMUTF8 = 2449,
1727 | SCI_FINDCOLUMN = 2456,
1728 | SCI_GETCARETSTICKY = 2457,
1729 | SCI_SETCARETSTICKY = 2458,
1730 | SCI_TOGGLECARETSTICKY = 2459,
1731 | SCI_SETPASTECONVERTENDINGS = 2467,
1732 | SCI_GETPASTECONVERTENDINGS = 2468,
1733 | SCI_SELECTIONDUPLICATE = 2469,
1734 | SC_ALPHA_TRANSPARENT = 0,
1735 | SC_ALPHA_OPAQUE = 255,
1736 | SC_ALPHA_NOALPHA = 256,
1737 | SCI_SETCARETLINEBACKALPHA = 2470,
1738 | SCI_GETCARETLINEBACKALPHA = 2471,
1739 | CARETSTYLE_INVISIBLE = 0,
1740 | CARETSTYLE_LINE = 1,
1741 | CARETSTYLE_BLOCK = 2,
1742 | SCI_SETCARETSTYLE = 2512,
1743 | SCI_GETCARETSTYLE = 2513,
1744 | SCI_SETINDICATORCURRENT = 2500,
1745 | SCI_GETINDICATORCURRENT = 2501,
1746 | SCI_SETINDICATORVALUE = 2502,
1747 | SCI_GETINDICATORVALUE = 2503,
1748 | SCI_INDICATORFILLRANGE = 2504,
1749 | SCI_INDICATORCLEARRANGE = 2505,
1750 | SCI_INDICATORALLONFOR = 2506,
1751 | SCI_INDICATORVALUEAT = 2507,
1752 | SCI_INDICATORSTART = 2508,
1753 | SCI_INDICATOREND = 2509,
1754 | SCI_SETPOSITIONCACHE = 2514,
1755 | SCI_GETPOSITIONCACHE = 2515,
1756 | SCI_COPYALLOWLINE = 2519,
1757 | SCI_GETCHARACTERPOINTER = 2520,
1758 | SCI_SETKEYSUNICODE = 2521,
1759 | SCI_GETKEYSUNICODE = 2522,
1760 | SCI_INDICSETALPHA = 2523,
1761 | SCI_INDICGETALPHA = 2524,
1762 | SCI_SETEXTRAASCENT = 2525,
1763 | SCI_GETEXTRAASCENT = 2526,
1764 | SCI_SETEXTRADESCENT = 2527,
1765 | SCI_GETEXTRADESCENT = 2528,
1766 | SCI_MARKERSYMBOLDEFINED = 2529,
1767 | SCI_MARGINSETTEXT = 2530,
1768 | SCI_MARGINGETTEXT = 2531,
1769 | SCI_MARGINSETSTYLE = 2532,
1770 | SCI_MARGINGETSTYLE = 2533,
1771 | SCI_MARGINSETSTYLES = 2534,
1772 | SCI_MARGINGETSTYLES = 2535,
1773 | SCI_MARGINTEXTCLEARALL = 2536,
1774 | SCI_MARGINSETSTYLEOFFSET = 2537,
1775 | SCI_MARGINGETSTYLEOFFSET = 2538,
1776 | SCI_ANNOTATIONSETTEXT = 2540,
1777 | SCI_ANNOTATIONGETTEXT = 2541,
1778 | SCI_ANNOTATIONSETSTYLE = 2542,
1779 | SCI_ANNOTATIONGETSTYLE = 2543,
1780 | SCI_ANNOTATIONSETSTYLES = 2544,
1781 | SCI_ANNOTATIONGETSTYLES = 2545,
1782 | SCI_ANNOTATIONGETLINES = 2546,
1783 | SCI_ANNOTATIONCLEARALL = 2547,
1784 | ANNOTATION_HIDDEN = 0,
1785 | ANNOTATION_STANDARD = 1,
1786 | ANNOTATION_BOXED = 2,
1787 | SCI_ANNOTATIONSETVISIBLE = 2548,
1788 | SCI_ANNOTATIONGETVISIBLE = 2549,
1789 | SCI_ANNOTATIONSETSTYLEOFFSET = 2550,
1790 | SCI_ANNOTATIONGETSTYLEOFFSET = 2551,
1791 | UNDO_MAY_COALESCE = 1,
1792 | SCI_ADDUNDOACTION = 2560,
1793 | SCI_CHARPOSITIONFROMPOINT = 2561,
1794 | SCI_CHARPOSITIONFROMPOINTCLOSE = 2562,
1795 | SCI_SETMULTIPLESELECTION = 2563,
1796 | SCI_GETMULTIPLESELECTION = 2564,
1797 | SCI_SETADDITIONALSELECTIONTYPING = 2565,
1798 | SCI_GETADDITIONALSELECTIONTYPING = 2566,
1799 | SCI_SETADDITIONALCARETSBLINK = 2567,
1800 | SCI_GETADDITIONALCARETSBLINK = 2568,
1801 | SCI_GETSELECTIONS = 2570,
1802 | SCI_CLEARSELECTIONS = 2571,
1803 | SCI_SETSELECTION = 2572,
1804 | SCI_ADDSELECTION = 2573,
1805 | SCI_SETMAINSELECTION = 2574,
1806 | SCI_GETMAINSELECTION = 2575,
1807 | SCI_SETSELECTIONNCARET = 2576,
1808 | SCI_GETSELECTIONNCARET = 2577,
1809 | SCI_SETSELECTIONNANCHOR = 2578,
1810 | SCI_GETSELECTIONNANCHOR = 2579,
1811 | SCI_SETSELECTIONNCARETVIRTUALSPACE = 2580,
1812 | SCI_GETSELECTIONNCARETVIRTUALSPACE = 2581,
1813 | SCI_SETSELECTIONNANCHORVIRTUALSPACE = 2582,
1814 | SCI_GETSELECTIONNANCHORVIRTUALSPACE = 2583,
1815 | SCI_SETSELECTIONNSTART = 2584,
1816 | SCI_GETSELECTIONNSTART = 2585,
1817 | SCI_SETSELECTIONNEND = 2586,
1818 | SCI_GETSELECTIONNEND = 2587,
1819 | SCI_SETRECTANGULARSELECTIONCARET = 2588,
1820 | SCI_GETRECTANGULARSELECTIONCARET = 2589,
1821 | SCI_SETRECTANGULARSELECTIONANCHOR = 2590,
1822 | SCI_GETRECTANGULARSELECTIONANCHOR = 2591,
1823 | SCI_SETRECTANGULARSELECTIONCARETVIRTUALSPACE = 2592,
1824 | SCI_GETRECTANGULARSELECTIONCARETVIRTUALSPACE = 2593,
1825 | SCI_SETRECTANGULARSELECTIONANCHORVIRTUALSPACE = 2594,
1826 | SCI_GETRECTANGULARSELECTIONANCHORVIRTUALSPACE = 2595,
1827 | SCVS_NONE = 0,
1828 | SCVS_RECTANGULARSELECTION = 1,
1829 | SCVS_USERACCESSIBLE = 2,
1830 | SCI_SETVIRTUALSPACEOPTIONS = 2596,
1831 | SCI_GETVIRTUALSPACEOPTIONS = 2597,
1832 | SCI_SETRECTANGULARSELECTIONMODIFIER = 2598,
1833 | SCI_GETRECTANGULARSELECTIONMODIFIER = 2599,
1834 | SCI_SETADDITIONALSELFORE = 2600,
1835 | SCI_SETADDITIONALSELBACK = 2601,
1836 | SCI_SETADDITIONALSELALPHA = 2602,
1837 | SCI_GETADDITIONALSELALPHA = 2603,
1838 | SCI_SETADDITIONALCARETFORE = 2604,
1839 | SCI_GETADDITIONALCARETFORE = 2605,
1840 | SCI_ROTATESELECTION = 2606,
1841 | SCI_SWAPMAINANCHORCARET = 2607,
1842 | SCI_STARTRECORD = 3001,
1843 | SCI_STOPRECORD = 3002,
1844 | SCI_SETLEXER = 4001,
1845 | SCI_GETLEXER = 4002,
1846 | SCI_COLOURISE = 4003,
1847 | SCI_SETPROPERTY = 4004,
1848 | KEYWORDSET_MAX = 8,
1849 | SCI_SETKEYWORDS = 4005,
1850 | SCI_SETLEXERLANGUAGE = 4006,
1851 | SCI_LOADLEXERLIBRARY = 4007,
1852 | SCI_GETPROPERTY = 4008,
1853 | SCI_GETPROPERTYEXPANDED = 4009,
1854 | SCI_GETPROPERTYINT = 4010,
1855 | SCI_GETSTYLEBITSNEEDED = 4011,
1856 | SC_MOD_INSERTTEXT = 0x1,
1857 | SC_MOD_DELETETEXT = 0x2,
1858 | SC_MOD_CHANGESTYLE = 0x4,
1859 | SC_MOD_CHANGEFOLD = 0x8,
1860 | SC_PERFORMED_USER = 0x10,
1861 | SC_PERFORMED_UNDO = 0x20,
1862 | SC_PERFORMED_REDO = 0x40,
1863 | SC_MULTISTEPUNDOREDO = 0x80,
1864 | SC_LASTSTEPINUNDOREDO = 0x100,
1865 | SC_MOD_CHANGEMARKER = 0x200,
1866 | SC_MOD_BEFOREINSERT = 0x400,
1867 | SC_MOD_BEFOREDELETE = 0x800,
1868 | SC_MULTILINEUNDOREDO = 0x1000,
1869 | SC_STARTACTION = 0x2000,
1870 | SC_MOD_CHANGEINDICATOR = 0x4000,
1871 | SC_MOD_CHANGELINESTATE = 0x8000,
1872 | SC_MOD_CHANGEMARGIN = 0x10000,
1873 | SC_MOD_CHANGEANNOTATION = 0x20000,
1874 | SC_MOD_CONTAINER = 0x40000,
1875 | SC_MODEVENTMASKALL = 0x7FFFF,
1876 | SC_SEARCHRESULT_LINEBUFFERMAXLENGTH = 1024,
1877 | SCEN_CHANGE = 768,
1878 | SCEN_SETFOCUS = 512,
1879 | SCEN_KILLFOCUS = 256,
1880 | SCK_DOWN = 300,
1881 | SCK_UP = 301,
1882 | SCK_LEFT = 302,
1883 | SCK_RIGHT = 303,
1884 | SCK_HOME = 304,
1885 | SCK_END = 305,
1886 | SCK_PRIOR = 306,
1887 | SCK_NEXT = 307,
1888 | SCK_DELETE = 308,
1889 | SCK_INSERT = 309,
1890 | SCK_ESCAPE = 7,
1891 | SCK_BACK = 8,
1892 | SCK_TAB = 9,
1893 | SCK_RETURN = 13,
1894 | SCK_ADD = 310,
1895 | SCK_SUBTRACT = 311,
1896 | SCK_DIVIDE = 312,
1897 | SCK_WIN = 313,
1898 | SCK_RWIN = 314,
1899 | SCK_MENU = 315,
1900 | SCMOD_NORM = 0,
1901 | SCMOD_SHIFT = 1,
1902 | SCMOD_CTRL = 2,
1903 | SCMOD_ALT = 4,
1904 | SCMOD_SUPER = 8,
1905 | SCN_STYLENEEDED = 2000,
1906 | SCN_CHARADDED = 2001,
1907 | SCN_SAVEPOINTREACHED = 2002,
1908 | SCN_SAVEPOINTLEFT = 2003,
1909 | SCN_MODIFYATTEMPTRO = 2004,
1910 | SCN_KEY = 2005,
1911 | SCN_DOUBLECLICK = 2006,
1912 | SCN_UPDATEUI = 2007,
1913 | SCN_MODIFIED = 2008,
1914 | SCN_MACRORECORD = 2009,
1915 | SCN_MARGINCLICK = 2010,
1916 | SCN_NEEDSHOWN = 2011,
1917 | SCN_PAINTED = 2013,
1918 | SCN_USERLISTSELECTION = 2014,
1919 | SCN_URIDROPPED = 2015,
1920 | SCN_DWELLSTART = 2016,
1921 | SCN_DWELLEND = 2017,
1922 | SCN_ZOOM = 2018,
1923 | SCN_HOTSPOTCLICK = 2019,
1924 | SCN_HOTSPOTDOUBLECLICK = 2020,
1925 | SCN_CALLTIPCLICK = 2021,
1926 | SCN_AUTOCSELECTION = 2022,
1927 | SCN_INDICATORCLICK = 2023,
1928 | SCN_INDICATORRELEASE = 2024,
1929 | SCN_AUTOCCANCELLED = 2025,
1930 | SCN_AUTOCCHARDELETED = 2026,
1931 | SCN_SCROLLED = 2080
1932 | }
1933 |
1934 | [StructLayout(LayoutKind.Sequential)]
1935 | public struct Sci_CharacterRange
1936 | {
1937 | public Sci_CharacterRange(int cpmin, int cpmax) { cpMin = cpmin; cpMax = cpmax; }
1938 | public int cpMin;
1939 | public int cpMax;
1940 | }
1941 |
1942 | public class Sci_TextRange : IDisposable
1943 | {
1944 | _Sci_TextRange _sciTextRange;
1945 | IntPtr _ptrSciTextRange;
1946 | bool _disposed = false;
1947 |
1948 | public Sci_TextRange(Sci_CharacterRange chrRange, int stringCapacity)
1949 | {
1950 | _sciTextRange.chrg = chrRange;
1951 | _sciTextRange.lpstrText = Marshal.AllocHGlobal(stringCapacity);
1952 | }
1953 | public Sci_TextRange(int cpmin, int cpmax, int stringCapacity)
1954 | {
1955 | _sciTextRange.chrg.cpMin = cpmin;
1956 | _sciTextRange.chrg.cpMax = cpmax;
1957 | _sciTextRange.lpstrText = Marshal.AllocHGlobal(stringCapacity);
1958 | }
1959 |
1960 | [StructLayout(LayoutKind.Sequential)]
1961 | struct _Sci_TextRange
1962 | {
1963 | public Sci_CharacterRange chrg;
1964 | public IntPtr lpstrText;
1965 | }
1966 |
1967 | public IntPtr NativePointer { get { _initNativeStruct(); return _ptrSciTextRange; } }
1968 | public string lpstrText { get { _readNativeStruct(); return Marshal.PtrToStringAnsi(_sciTextRange.lpstrText); } }
1969 | public Sci_CharacterRange chrg { get { _readNativeStruct(); return _sciTextRange.chrg; } set { _sciTextRange.chrg = value; _initNativeStruct(); } }
1970 | void _initNativeStruct()
1971 | {
1972 | if (_ptrSciTextRange == IntPtr.Zero)
1973 | _ptrSciTextRange = Marshal.AllocHGlobal(Marshal.SizeOf(_sciTextRange));
1974 | Marshal.StructureToPtr(_sciTextRange, _ptrSciTextRange, false);
1975 | }
1976 | void _readNativeStruct()
1977 | {
1978 | if (_ptrSciTextRange != IntPtr.Zero)
1979 | _sciTextRange = (_Sci_TextRange)Marshal.PtrToStructure(_ptrSciTextRange, typeof(_Sci_TextRange));
1980 | }
1981 |
1982 | public void Dispose()
1983 | {
1984 | if (!_disposed)
1985 | {
1986 | if (_sciTextRange.lpstrText != IntPtr.Zero) Marshal.FreeHGlobal(_sciTextRange.lpstrText);
1987 | if (_ptrSciTextRange != IntPtr.Zero) Marshal.FreeHGlobal(_ptrSciTextRange);
1988 | _disposed = true;
1989 | }
1990 | }
1991 | ~Sci_TextRange()
1992 | {
1993 | Dispose();
1994 | }
1995 | }
1996 |
1997 | public class Sci_TextToFind : IDisposable
1998 | {
1999 | _Sci_TextToFind _sciTextToFind;
2000 | IntPtr _ptrSciTextToFind;
2001 | bool _disposed = false;
2002 |
2003 | public Sci_TextToFind(Sci_CharacterRange chrRange, string searchText)
2004 | {
2005 | _sciTextToFind.chrg = chrRange;
2006 | _sciTextToFind.lpstrText = Marshal.StringToHGlobalAnsi(searchText);
2007 | }
2008 | public Sci_TextToFind(int cpmin, int cpmax, string searchText)
2009 | {
2010 | _sciTextToFind.chrg.cpMin = cpmin;
2011 | _sciTextToFind.chrg.cpMax = cpmax;
2012 | _sciTextToFind.lpstrText = Marshal.StringToHGlobalAnsi(searchText);
2013 | }
2014 |
2015 | [StructLayout(LayoutKind.Sequential)]
2016 | struct _Sci_TextToFind
2017 | {
2018 | public Sci_CharacterRange chrg;
2019 | public IntPtr lpstrText;
2020 | public Sci_CharacterRange chrgText;
2021 | }
2022 |
2023 | public IntPtr NativePointer { get { _initNativeStruct(); return _ptrSciTextToFind; } }
2024 | public string lpstrText { set { _freeNativeString(); _sciTextToFind.lpstrText = Marshal.StringToHGlobalAnsi(value); } }
2025 | public Sci_CharacterRange chrg { get { _readNativeStruct(); return _sciTextToFind.chrg; } set { _sciTextToFind.chrg = value; _initNativeStruct(); } }
2026 | public Sci_CharacterRange chrgText { get { _readNativeStruct(); return _sciTextToFind.chrgText; } }
2027 | void _initNativeStruct()
2028 | {
2029 | if (_ptrSciTextToFind == IntPtr.Zero)
2030 | _ptrSciTextToFind = Marshal.AllocHGlobal(Marshal.SizeOf(_sciTextToFind));
2031 | Marshal.StructureToPtr(_sciTextToFind, _ptrSciTextToFind, false);
2032 | }
2033 | void _readNativeStruct()
2034 | {
2035 | if (_ptrSciTextToFind != IntPtr.Zero)
2036 | _sciTextToFind = (_Sci_TextToFind)Marshal.PtrToStructure(_ptrSciTextToFind, typeof(_Sci_TextToFind));
2037 | }
2038 | void _freeNativeString()
2039 | {
2040 | if (_sciTextToFind.lpstrText != IntPtr.Zero) Marshal.FreeHGlobal(_sciTextToFind.lpstrText);
2041 | }
2042 |
2043 | public void Dispose()
2044 | {
2045 | if (!_disposed)
2046 | {
2047 | _freeNativeString();
2048 | if (_ptrSciTextToFind != IntPtr.Zero) Marshal.FreeHGlobal(_ptrSciTextToFind);
2049 | _disposed = true;
2050 | }
2051 | }
2052 | ~Sci_TextToFind()
2053 | {
2054 | Dispose();
2055 | }
2056 | }
2057 | #endregion
2058 |
2059 | #region " Platform "
2060 | public class Win32
2061 | {
2062 | [DllImport("user32")]
2063 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, int wParam, NppMenuCmd lParam);
2064 | [DllImport("user32")]
2065 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, int wParam, IntPtr lParam);
2066 | [DllImport("user32")]
2067 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, int wParam, int lParam);
2068 | [DllImport("user32")]
2069 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, int wParam, out int lParam);
2070 | [DllImport("user32")]
2071 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, IntPtr wParam, int lParam);
2072 | [DllImport("user32")]
2073 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, int wParam, ref LangType lParam);
2074 | [DllImport("user32")]
2075 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, int wParam, [MarshalAs(UnmanagedType.LPWStr)] StringBuilder lParam);
2076 | [DllImport("user32")]
2077 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, int wParam, [MarshalAs(UnmanagedType.LPWStr)] string lParam);
2078 | [DllImport("user32")]
2079 | public static extern IntPtr SendMessage(IntPtr hWnd, NppMsg Msg, IntPtr wParam, [MarshalAs(UnmanagedType.LPWStr)] string lParam);
2080 |
2081 | [DllImport("user32")]
2082 | public static extern IntPtr SendMessage(IntPtr hWnd, SciMsg Msg, int wParam, IntPtr lParam);
2083 | [DllImport("user32")]
2084 | public static extern IntPtr SendMessage(IntPtr hWnd, SciMsg Msg, int wParam, string lParam);
2085 | [DllImport("user32")]
2086 | public static extern IntPtr SendMessage(IntPtr hWnd, SciMsg Msg, int wParam, [MarshalAs(UnmanagedType.LPStr)] StringBuilder lParam);
2087 | [DllImport("user32")]
2088 | public static extern IntPtr SendMessage(IntPtr hWnd, SciMsg Msg, int wParam, int lParam);
2089 |
2090 | public const int MAX_PATH = 260;
2091 | [DllImport("kernel32")]
2092 | public static extern int GetPrivateProfileInt(string lpAppName, string lpKeyName, int nDefault, string lpFileName);
2093 | [DllImport("kernel32.dll")]
2094 | public static extern int GetPrivateProfileString(string lpAppName, string lpKeyName, string lpDefault, StringBuilder lpReturnedString, int nSize, string lpFileName);
2095 | [DllImport("kernel32")]
2096 | public static extern bool WritePrivateProfileString(string lpAppName, string lpKeyName, string lpString, string lpFileName);
2097 |
2098 | public const int MF_BYCOMMAND = 0;
2099 | public const int MF_CHECKED = 8;
2100 | public const int MF_UNCHECKED = 0;
2101 | [DllImport("user32")]
2102 | public static extern IntPtr GetMenu(IntPtr hWnd);
2103 | [DllImport("user32")]
2104 | public static extern int CheckMenuItem(IntPtr hmenu, int uIDCheckItem, int uCheck);
2105 |
2106 | public const int WM_CREATE = 1;
2107 | }
2108 |
2109 | public class ClikeStringArray : IDisposable
2110 | {
2111 | IntPtr _nativeArray;
2112 | List _nativeItems;
2113 | bool _disposed = false;
2114 |
2115 | public ClikeStringArray(int num, int stringCapacity)
2116 | {
2117 | _nativeArray = Marshal.AllocHGlobal((num + 1) * IntPtr.Size);
2118 | _nativeItems = new List();
2119 | for (int i = 0; i < num; i++)
2120 | {
2121 | IntPtr item = Marshal.AllocHGlobal(stringCapacity);
2122 | Marshal.WriteIntPtr((IntPtr)((int)_nativeArray + (i * IntPtr.Size)), item);
2123 | _nativeItems.Add(item);
2124 | }
2125 | Marshal.WriteIntPtr((IntPtr)((int)_nativeArray + (num * IntPtr.Size)), IntPtr.Zero);
2126 | }
2127 |
2128 | public IntPtr NativePointer { get { return _nativeArray; } }
2129 | public List ManagedStringsAnsi { get { return _getManagedItems(false); } }
2130 | public List ManagedStringsUnicode { get { return _getManagedItems(true); } }
2131 | List _getManagedItems(bool unicode)
2132 | {
2133 | List _managedItems = new List();
2134 | for (int i = 0; i < _nativeItems.Count; i++)
2135 | {
2136 | if (unicode) _managedItems.Add(Marshal.PtrToStringUni(_nativeItems[i]));
2137 | else _managedItems.Add(Marshal.PtrToStringAnsi(_nativeItems[i]));
2138 | }
2139 | return _managedItems;
2140 | }
2141 |
2142 | public void Dispose()
2143 | {
2144 | if (!_disposed)
2145 | {
2146 | for (int i = 0; i < _nativeItems.Count; i++)
2147 | if (_nativeItems[i] != IntPtr.Zero) Marshal.FreeHGlobal(_nativeItems[i]);
2148 | if (_nativeArray != IntPtr.Zero) Marshal.FreeHGlobal(_nativeArray);
2149 | _disposed = true;
2150 | }
2151 | }
2152 | ~ClikeStringArray()
2153 | {
2154 | Dispose();
2155 | }
2156 | }
2157 | #endregion
2158 | }
2159 |
--------------------------------------------------------------------------------
/Merge files in one/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/Properties/AssemblyInfo.cs
--------------------------------------------------------------------------------
/Merge files in one/Properties/Resources.Designer.cs:
--------------------------------------------------------------------------------
1 | //------------------------------------------------------------------------------
2 | //
3 | // This code was generated by a tool.
4 | // Runtime Version:4.0.30319.42000
5 | //
6 | // Changes to this file may cause incorrect behavior and will be lost if
7 | // the code is regenerated.
8 | //
9 | //------------------------------------------------------------------------------
10 |
11 | namespace Merge_files_in_one.Properties {
12 | using System;
13 |
14 |
15 | ///
16 | /// A strongly-typed resource class, for looking up localized strings, etc.
17 | ///
18 | // This class was auto-generated by the StronglyTypedResourceBuilder
19 | // class via a tool like ResGen or Visual Studio.
20 | // To add or remove a member, edit your .ResX file then rerun ResGen
21 | // with the /str option, or rebuild your VS project.
22 | [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0")]
23 | [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
24 | [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
25 | internal class Resources {
26 |
27 | private static global::System.Resources.ResourceManager resourceMan;
28 |
29 | private static global::System.Globalization.CultureInfo resourceCulture;
30 |
31 | [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
32 | internal Resources() {
33 | }
34 |
35 | ///
36 | /// Returns the cached ResourceManager instance used by this class.
37 | ///
38 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
39 | internal static global::System.Resources.ResourceManager ResourceManager {
40 | get {
41 | if (object.ReferenceEquals(resourceMan, null)) {
42 | global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("Merge_files_in_one.Properties.Resources", typeof(Resources).Assembly);
43 | resourceMan = temp;
44 | }
45 | return resourceMan;
46 | }
47 | }
48 |
49 | ///
50 | /// Overrides the current thread's CurrentUICulture property for all
51 | /// resource lookups using this strongly typed resource class.
52 | ///
53 | [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
54 | internal static global::System.Globalization.CultureInfo Culture {
55 | get {
56 | return resourceCulture;
57 | }
58 | set {
59 | resourceCulture = value;
60 | }
61 | }
62 | }
63 | }
64 |
--------------------------------------------------------------------------------
/Merge files in one/Properties/Resources.resx:
--------------------------------------------------------------------------------
1 |
2 |
3 |
62 |
63 |
64 |
65 |
66 |
67 |
68 |
69 |
70 |
71 |
72 |
73 |
74 |
75 |
76 |
77 |
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 | text/microsoft-resx
110 |
111 |
112 | 2.0
113 |
114 |
115 | System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
116 |
117 |
118 | System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
119 |
120 |
--------------------------------------------------------------------------------
/Merge files in one/Properties/star.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/Properties/star.png
--------------------------------------------------------------------------------
/Merge files in one/Properties/star_bmp.bmp:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/Properties/star_bmp.bmp
--------------------------------------------------------------------------------
/Merge files in one/Resources/Thumbs.db:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/Resources/Thumbs.db
--------------------------------------------------------------------------------
/Merge files in one/UnmanagedExports.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Runtime.InteropServices;
3 | using NppPluginNET;
4 | using NppPlugin.DllExport;
5 |
6 | namespace Merge_files_in_one
7 | {
8 | class UnmanagedExports
9 | {
10 | [DllExport(CallingConvention=CallingConvention.Cdecl)]
11 | static bool isUnicode()
12 | {
13 | return true;
14 | }
15 |
16 | [DllExport(CallingConvention = CallingConvention.Cdecl)]
17 | static void setInfo(NppData notepadPlusData)
18 | {
19 | PluginBase.nppData = notepadPlusData;
20 | Main.CommandMenuInit();
21 | }
22 |
23 | [DllExport(CallingConvention = CallingConvention.Cdecl)]
24 | static IntPtr getFuncsArray(ref int nbF)
25 | {
26 | nbF = PluginBase._funcItems.Items.Count;
27 | return PluginBase._funcItems.NativePointer;
28 | }
29 |
30 | [DllExport(CallingConvention = CallingConvention.Cdecl)]
31 | static uint messageProc(uint Message, IntPtr wParam, IntPtr lParam)
32 | {
33 | return 1;
34 | }
35 |
36 | static IntPtr _ptrPluginName = IntPtr.Zero;
37 | [DllExport(CallingConvention = CallingConvention.Cdecl)]
38 | static IntPtr getName()
39 | {
40 | if (_ptrPluginName == IntPtr.Zero)
41 | _ptrPluginName = Marshal.StringToHGlobalUni(Main.PluginName);
42 | return _ptrPluginName;
43 | }
44 |
45 | [DllExport(CallingConvention = CallingConvention.Cdecl)]
46 | static void beNotified(IntPtr notifyCode)
47 | {
48 | SCNotification nc = (SCNotification)Marshal.PtrToStructure(notifyCode, typeof(SCNotification));
49 | if (nc.nmhdr.code == (uint)NppMsg.NPPN_TBMODIFICATION)
50 | {
51 | PluginBase._funcItems.RefreshItems();
52 | Main.SetToolBarIcon();
53 | }
54 | else if (nc.nmhdr.code == (uint)NppMsg.NPPN_SHUTDOWN)
55 | {
56 | Main.PluginCleanUp();
57 | Marshal.FreeHGlobal(_ptrPluginName);
58 | }
59 | }
60 | }
61 | }
62 |
--------------------------------------------------------------------------------
/Merge files in one/obj/Debug/TempPE/Properties.Resources.Designer.cs.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/obj/Debug/TempPE/Properties.Resources.Designer.cs.dll
--------------------------------------------------------------------------------
/Merge files in one/obj/Release/TempPE/Properties.Resources.Designer.cs.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/gurikbal/Merge-files-in-one/6815419abaa9ed72fb87d2d4fb239db6b332f095/Merge files in one/obj/Release/TempPE/Properties.Resources.Designer.cs.dll
--------------------------------------------------------------------------------
/appveyor.yml:
--------------------------------------------------------------------------------
1 | version: 1.2.0.{build}
2 | image: Visual Studio 2017
3 |
4 |
5 | platform:
6 | - x86
7 | - x64
8 |
9 | configuration:
10 | - Debug
11 | - Release
12 |
13 | install:
14 | - if "%platform%"=="x64" set archi=amd64
15 | - if "%platform%"=="x64" set platform_input=x64
16 |
17 | - if "%platform%"=="x86" set archi=x86
18 | - if "%platform%"=="x86" set platform_input=x86
19 |
20 | - call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" %archi%
21 |
22 | build_script:
23 | - cd "%APPVEYOR_BUILD_FOLDER%"\
24 | - msbuild "Merge files in one.sln" /m /p:configuration="%configuration%" /p:platform="%platform_input%" /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
25 |
26 | after_build:
27 | - cd "%APPVEYOR_BUILD_FOLDER%"\"Merge files in one"\
28 | - ps: >-
29 |
30 | Push-AppveyorArtifact "bin\$($env:PLATFORM_INPUT)\$($env:CONFIGURATION)\Merge files in one.dll" -FileName Merge_files_in_one.dll
31 |
32 | if ($($env:APPVEYOR_REPO_TAG) -eq "true" -and $env:CONFIGURATION -eq "Release") {
33 | if($env:PLATFORM_INPUT -eq "x64"){
34 | $ZipFileName = "Merge_files_in_one_$($env:APPVEYOR_REPO_TAG_NAME)_x64.zip"
35 | 7z a $ZipFileName "bin\$env:PLATFORM_INPUT\$env:CONFIGURATION\Merge files in one.dll"
36 | }
37 | if($env:PLATFORM_INPUT -eq "x86"){
38 | $ZipFileName = "Merge_files_in_one_$($env:APPVEYOR_REPO_TAG_NAME)_x86.zip"
39 | 7z a $ZipFileName "bin\$env:PLATFORM_INPUT\$env:CONFIGURATION\Merge files in one.dll"
40 | }
41 | }
42 |
43 | artifacts:
44 | - path: Merge_files_in_one_*.zip
45 | name: releases
46 |
47 | deploy:
48 | provider: GitHub
49 | auth_token:
50 | secure: !!TODO, see https://www.appveyor.com/docs/deployment/github/#provider-settings!!
51 | artifact: releases
52 | draft: false
53 | prerelease: false
54 | force_update: true
55 | on:
56 | appveyor_repo_tag: true
57 | configuration: Release
58 |
--------------------------------------------------------------------------------