libosmscout icon indicating copy to clipboard operation
libosmscout copied to clipboard

Modernize styleeditor

Open janbar opened this issue 1 year ago • 2 comments

This is the proposal on my rework of the tool to edit style sheet. The target is to modernize the GUI tool, improve performances, and make it work with Qt5.15 and Qt6.

The new one: Capture d’écran du 2024-08-28 12-46-36

I fixed some performance issues with the editor and the gui. It implements natively the block indentation, and the editing is smooth with the style analyser.

The customized shortcuts are:

  • Ctrl+S: Save
  • Ctrl+C: Copy selected block
  • Ctrl+X: Cut selected block
  • Ctrl+V: Paste
  • Ctrl+F : focus the search text input
  • F3: Find next
  • Shift+F3: Find previous
  • PageDown: move cursor to next page
  • PageUp: move cursor to previous page
  • Tab: insert indent or indent+ selected block
  • Shift+Tab: indent- selected block

janbar avatar Aug 25 '24 14:08 janbar

@Framstag , the work is finished.

I cannot test it with Windows because I haven't one. But I tested it with Linux and MacOS.

janbar avatar Aug 28 '24 10:08 janbar

Please see PR #1591. I will rebase this after the resolution.

janbar avatar Aug 30 '24 11:08 janbar

@janbar : Somehwere in between you claimed to be finished, but you are obviously not ;-) Please signal again, if you are finished.

Framstag avatar Aug 30 '24 14:08 Framstag

@Framstag , it is finished and refine ;-). But it works only with the PR #1591, else the analyser will crash the app. So I rebase it now without including the fix #1591. And let you merge it if you approve it !

Note: If you try it on Windows, you should compile it using Qt5.15.13 (same version provided with Ubuntu 24 and many other Linux). Unfortunately Qt no longer provides a pre-compiled framework after 5.15.2. Using Qt5.15.2, you will get a bug in QSyntaxHighlighter, and sometimes the redraw will not processed. To fix it you could use the pre-compiled framework Qt6.7.2.

janbar avatar Aug 30 '24 15:08 janbar