Вопрос

Hi I just noticed that if you creating a new view on jEdit, when you editing the new one, it affected the text on the original window's text as well, how could I create a New view that allow the user to duplicate data for the current shown view only and not effecting the old ones?

I try to find solutions on the source code, then I find seems there are setting that related to this: http://www.jedit.org/users-guide/buffersets.html but I didn't find the selection mentioned on my setting.

Это было полезно?

Решение

For having independent edit windows, you have to start independent jEdit instances with independent settings directories. You can either start a new jEdit instance without restoring any settings (this includes also plugins installed to the settings directory which is the default) by using the -nosettings parameter, or you can start a second jEdit instance with a different settings directory with -settings=/path/to/settings/directory which has independent settings like open files, installed plugins to settings directory and so on. You could copy your existing settings directory and delete the file /path/to/settings/diretory/server to have a copy of your existing settings in the second instance. But from then on, the settings are independent and if you change settings, plugins, and so on in one instance, it will not resemble in the other instance unless you sync your settings directories again.

Even with two independent running jEdit instances, if you save the file in one instance, the other instance will pop up a message box informing you that the file changed on disk and ask you what to do if you didn't configure a default option.

Probably the easiest would be to simply open a new buffer and copy & paste the contents of the buffer in question to this new buffer. This could also be done by a Macro which you can then also assign a keyboard shortcut or toolbar button to.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top