Alexey-T / CudaText

Cross-platform text editor, written in Free Pascal
Mozilla Public License 2.0
2.49k stars 170 forks source link

CudaText doesn't start if you disable the window frame (Linux). #2793

Closed VicDobrov closed 3 years ago

VicDobrov commented 4 years ago

Window manager: kwin If you disable the window borders (create a rule - without borders), the editor does not start. It is sad…

Alexey-T commented 4 years ago

What linux distro do I need, to not break my Ubuntu ? How to setup kwin in it? How to turn off border?

Alexey-T commented 4 years ago

Pls test this simple dialog app http://uvviewsoft.com/c/testmsgboxes.zip it if don't work too, we have lazarus gtk2 bug.

VicDobrov commented 4 years ago

I tested it, everything is fine! Created rules that disable the window frame. Launched the dialogue - all the dialogue normally displayed without a frame.

The rule the kwin Window manager: "Hide the title and border of a window" Force

If you create a similar rule for CudaText, the program will not start. It will be the maximum load of one processor core… Perhaps the reason for the hang is that the editor remembers the geometry of its window itself.

Any Linux (I have Arch Linux). file: $HOME/.config/kwinrulesrc [$Version] update_info=kwinrules.upd:replace-placement-string-to-enum [1] Description=Settings testmsgboxes clientmachinematch=0 noborder=true noborderrule=2 title=StrCaption titlematch=1 types=32 wmclass=testmsgboxes wmclassmatch=1 [2] Description=Settings testmsgboxes clientmachinematch=0 noborder=true noborderrule=2 title=Test for various message-boxes titlematch=1 types=1 wmclass=testmsgboxes wmclassmatch=1

VicDobrov commented 4 years ago

I don't know how to build from sources. ;-(

Instructions on how to disable the window frame for 1) copy the rules file, the text of which I gave earlier: $HOME/. config/kwinrulesrc 2) Install Desktop Environment: plasma or LXDE or LXQt 3) run "Default applications for LXSession"for LXDE. For LXQt, run Session Settings. 4) select kwin_x11 as the window Manager 5) launch the program, press Alt+F3, select the submenu item: Window parameters. 6) add a rule: Hide the title and borders of the window 7) select the launch type For this rule: «Force» 8) close the app and start it again...

The point is for the window Manager to load rules that allow the application to run without a window frame. The rules are supported by many window managers: openbox, awesome, icewm, and many others…

Alexey-T commented 4 years ago

If you will get Lazarus, test the issue on it, pls?

VicDobrov commented 4 years ago

Test results — Lazarus IDE with the window frame forcibly disabled runs without errors.

Alexey-T commented 4 years ago

Hm, so I need to test it myself.. pls wait.

VicDobrov commented 4 years ago

A small addition: Linux window Manager (such as kwin) searches for rules for a specific application's window class, such as Cuda Test As a result, the Cuda Test window is created immediately without the window frame, if the option is available: noborder=true

Alexey-T commented 4 years ago

sorry, no time to test this: I will need to install new Linux (easy) and follow config steps (hard for me), and install fpcupdeluxe, and compile CudaText.

CudaText compile info: https://wiki.freepascal.org/CudaText#How_to_compile_CudaText

Alexey-T commented 3 years ago

no time to test/setup this.