Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[feature] 自动识别 codepage #877

Open
transtone opened this issue Sep 27, 2024 · 2 comments
Open

[feature] 自动识别 codepage #877

transtone opened this issue Sep 27, 2024 · 2 comments
Labels
✅enhancement 💪needs contribution This issue can not be fixed by me, contribution is welcome

Comments

@transtone
Copy link

transtone commented Sep 27, 2024

有朋友已经做了一个修改版

这是他的修改列表:

修改优化列表:
1.原生简体中文,完善官方中文有少数几处小问题。可以加载官方版本的多国语言包。
2.默认情况下自动检测文件编码(代码页)。可以禁用检测文件编码功能(禁用后与原版运行效果一致),方法是在Notepad4.ini中加入如下代码:

[Settings]
NoDetectEncoding=1

3.没有ini文件情况下(第一次启动),默认显示到第一个显示屏上,窗口大小为显示屏三分之二大小,桌面居中。
4.以管理员身份启动(UAC开启情况下),支持拖放文件:暂时只能拖到工具栏上,不能拖到编辑框中(目前基于Scintilla组件的所有编辑器都是这样)。
5.修改默认的文件名为“无标题”,修改窗口类名为“Notepad“,即保持与Windows记事本一致。
6.添加mugen的文件类型语法高亮显示。

@zufuliu
Copy link
Owner

zufuliu commented Sep 27, 2024

You need to ask the author to upstream his code.

@zufuliu
Copy link
Owner

zufuliu commented Sep 27, 2024

4.以管理员身份启动(UAC开启情况下),支持拖放文件:暂时只能拖到工具栏上,不能拖到编辑框中(目前基于Scintilla组件的所有编辑器都是这样)。

The code for this non-standard behavior is commented out:

notepad4/src/Notepad4.cpp

Lines 1876 to 1883 in 85d1f29

// Drag & Drop
#if 0//_WIN32_WINNT >= _WIN32_WINNT_WIN7
// enable drop file onto non-client area for elevated Notepad4
ChangeWindowMessageFilterEx(hwnd, WM_DROPFILES, MSGFLT_ADD, nullptr);
ChangeWindowMessageFilterEx(hwnd, WM_COPYDATA, MSGFLT_ADD, nullptr);
ChangeWindowMessageFilterEx(hwnd, 0x0049 /*WM_COPYGLOBALDATA*/, MSGFLT_ADD, nullptr);
#endif
DragAcceptFiles(hwnd, TRUE);

@zufuliu zufuliu added the 💪needs contribution This issue can not be fixed by me, contribution is welcome label Sep 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✅enhancement 💪needs contribution This issue can not be fixed by me, contribution is welcome
Projects
None yet
Development

No branches or pull requests

2 participants