taqueci / redmine_wysiwyg_editor

Redmine WYSIWYG Editor plugin
GNU General Public License v2.0
115 stars 27 forks source link

Syntax highliting in code mode #41

Open dinya opened 5 years ago

dinya commented 5 years ago

Dear @taqueci

Thanks for plugin. It is very nice.

What about to add the Markdown/Textile syntax highliting in code mode?

See for example:

  1. https://github.com/gjroelofs/redmine_codemirror
  2. https://github.com/Lichtbit/redmine_sublime_markdown_codemirror
taqueci commented 5 years ago

Hi @dinya

I am analyzing the implementation of both the plugins, but it's difficult for me. :scream: Please don't get your hopes up.

martincizek commented 3 years ago

FYI - we have solved this, it's connected with slight format processing redesign / refactoring that allows more further improvements like macro support. Will submit a PR soon, stay tuned! :-)

dinya commented 3 years ago

@martincizek any news?

martincizek commented 3 years ago

@martincizek any news?

I'm not sure if I understood your issue well. I thought it was about code blocks not actually showing the syntax highlighting in visual mode, which is what we resolved. redmine_wysiwyg_editor uses TinyMCE's codesample plugin for code blocks. The integration with codesample plugin works correctly with our changes.

The other two interpretations would be:

  1. You want highlighted markup text source editor for the Redmine texts (i.e. the tab which is currently not affected by redmine_wysiwyg_editor). This is a completely different functionality from redmine_wysiwyg_editor. If it were added, redmine_wysiwyg_editor would then actually act as two plugins :) ... Check out the redmine_codemirror plugin - is it what you're looking for?
  2. You want syntax highlighting when editing code snippets within the visual editor - then it would be about modifying / replacing the functionality of the current TinyMCE's codesample plugin, which highlights syntax in the visual editor component, but not during the actual editing of the code snippet. I can imagine something like codemirror can be used in place of the current codesample plugin now.