Alexey-T / CudaText

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

Saving on macOS adds 's' char #4266

Closed sigzero closed 1 year ago

sigzero commented 2 years ago

I don't know if this happens on other operating systems but...when I save a file, the file saves and cudatext prints an "s" as well.

Example:

define name():
    print("Sigzero")
|  <<< cursor

After:

define name():
    print("Sigzero")
s| <<< cursor
Alexey-T commented 2 years ago

@veksha @jairomartineza Do you confirm it on macOS?

veksha commented 2 years ago

image

this key combination doesn't print "s" for me. even if I hold these keys for a while. can't reproduce on MacOS 11.6.8 (inside virtual machine)

Alexey-T commented 2 years ago

@sigzero Let's make a test:

JairoMartinezA commented 2 years ago

@sigzero are you using a previous version of CudaText?

Yes Alex I remember the same issue a few days ago, but currently with last version 1.168.5 I cannot reproduce the error anymore.

Alexey-T commented 2 years ago

The bugreport in the lazarus bugtracker: https://gitlab.com/freepascal.org/lazarus/lazarus/-/issues/39854

veksha commented 2 years ago

I can reproduce it inside Lazarus using ⌘-r key only (not ⌘-s) but inside CudaText all is ok for me :confused:

Andreas0602 commented 1 year ago

I have the same problem. It happens when I go to Options > Settings - default/user, change something in user.json, and then press command+S. It doesn't happen with txt files.

Alexey-T commented 1 year ago

It happens when you have splitted view (settings- default/user gives it)? but not in single view (settings - user)?

Andreas0602 commented 1 year ago

It happens when you have splitted view (settings- default/user gives it)? but not in single view (settings - user)?

That is correct.

One more point: To reproduce the issue, I must delete all files whose name starts with "history" from the directory ~/Library/Application Support/CudaText/settings/ before starting CudaText.

Andreas0602 commented 1 year ago

Update: I'm no longer able to reproduce this issue. It seems to be gone. Using cudatext-macos-cocoa-amd64-1.182.0.1.

Alexey-T commented 1 year ago

Tks for testing.

Alexey-T commented 1 year ago

This Lazarus fix fixes the similar issue: Command+R typed 'R' char in IDE. https://gitlab.com/freepascal.org/lazarus/lazarus/-/commit/770e392d8e1fdc4d371c78da423ec7b2ce69db4a

but, our issue was fixed already. strange.