pbek / QOwnNotes

QOwnNotes is a plain-text file notepad and todo-list manager with Markdown support and Nextcloud / ownCloud integration.
https://www.qownnotes.org/
GNU General Public License v2.0
4.67k stars 413 forks source link

Text cursor indicator #1923

Closed skaviouz closed 3 years ago

skaviouz commented 3 years ago

Issue assistant doesn't work, so I post manually? Type of inquiry: Issue Title: Text cursor indicator

Expected behaviour

When I use a text cursor indicator: Windows 10 Settings > Ease of Access > Text cursor [Vision] > Turn on text cursor indicator [enabled]

The indicator should be where you would expect it.

Actual behaviour

There is an offset where the cursor should be for the first line, the second line seems to be more off, and third and further seems to ignore the y axis all together.

Note: The input fields in settings have the same issue.

Example Video (GIF)

Steps to reproduce

See animated gif (If you need me to reupload I can) Note: You have to lose focus and regain focus for the indicator to appear when leaving settings (e.g. click anywhere not within bounds of the textArea container or lose focus on the entire app then refocus on it - like when you alt-tab back and forth - or double tab the windows key then click somewhere in the text on a non-empty line) Note 2: The above note is a secondary bug? The indicator should show up on empty lines too? Atleast it does in other apps, but honestly there is already another active line indicator in the app by default, so it's really up to you guys for the secondary bug.

Output from the debug section in the settings dialog

(Click here to Expand) QOwnNotes Debug Information =========================== ## General Info **Current Date**: `Tue Oct 27 07:36:35 2020` **Version**: `20.10.7` **Build date**: `Oct 24 2020` **Build number**: `774` **Platform**: `windows` **Operating System**: `Windows 10 (10.0)` **Build architecture**: `x86_64` **Current architecture**: `x86_64` **Release**: `GitHub Actions` **Qt Version (build)**: `5.13.2` **Qt Version (runtime)**: `5.13.2` **Portable mode**: `no` **Settings path / key**: `\HKEY_CURRENT_USER\Software\PBE\QOwnNotes` **Application database path**: `C:\Users\erich\AppData\Roaming\PBE\QOwnNotes\QOwnNotes.sqlite` **Application arguments**: `C:\Users\erich\Desktop\mobile\_APPs\QOwnNotes_v20.10.7\QOwnNotes.exe` **Qt Debug**: `0` **Locale (system)**: `en_US` **Locale (interface)**: *empty* **Primary screen resolution**: `1366x768` **Icon theme**: `breeze-qownnotes` **Notes in current note folder**: `4` **Calendar items**: `0` **Enabled scripts**: `0` ## Server Info **serverUrl**: *empty* **appIsValid**: `no` **notesPathExists**: *empty* **connectionErrorMessage**: *empty* ## Spellchecking **Enabled**: `false` **Selected language**: *empty* **Language codes**: *empty* **Language names**: *empty* **Application dictionaries path**: `C:\Users\erich\AppData\Roaming\PBE\QOwnNotes\dicts` ## Note folders **currentNoteFolderId**: `1` ### Note folder `default` **id**: `1` **isCurrent**: `yes` **activeTagId**: `0` **localPath**: `C:\Users\erich\Google Drive\_Notes` **remotePath**: `Notes` **cloudConnectionId**: `1` **isShowSubfolders**: `yes` **isUseGit**: `no` **activeNoteSubFolder name**: `Research` **database file**: `C:\Users\erich\Google Drive\_Notes\notes.sqlite` ## Cloud connections ### Cloud connection `Default` **id**: `1` **isCurrent**: `yes` **serverUrl**: *empty* **username**: *empty* ## Enabled scripts ## Settings **ActiveNoteHistoryItem** (NoteHistoryItem): `` **Debug/fakeOldVersionNumber** (QString): `false` **Debug/fileLogging** (QString): `true` **Editor/CurrentSchemaKey** (QString): `EditorColorSchema-6033d61b-cb96-46d5-a3a8-20d5172017eb` **Editor/autoBracketClosing** (QString): `true` **Editor/autoBracketRemoval** (QString): `true` **Editor/disableCursorBlinking** (QString): `false` **Editor/editorWidthInDFMOnly** (QString): `true` **Editor/highlightCurrentLine** (QString): `true` **Editor/indentSize** (int): `4` **Editor/removeTrainingSpaces** (QString): `false` **Editor/useTabIndent** (QString): `true` **Editor/vimMode** (QString): `false` **IssueAssistantDialog/geometry** (QByteArray): `` **LastUpdateCheck** (QDateTime): `2020-10-27T07:12:06.978` **MainWindow/geometry** (QByteArray): `` **MainWindow/mainToolBar.iconSize** (int): `24` **MainWindow/menuBarGeometry** (QByteArray): `` **MainWindow/noteTextEdit.code.font** (QString): `Roboto Mono,10,-1,5,50,0,0,0,0,0,Regular` **MainWindow/noteTextEdit.font** (QString): `Roboto,9,-1,5,50,0,0,0,0,0,Regular` **MainWindow/noteTextView.code.font** (QString): `Courier New,9,-1,2,50,0,0,0,0,0` **MainWindow/noteTextView.font** (QString): `MS Shell Dlg 2,8.25,-1,5,50,0,0,0,0,0` **MainWindow/noteTextView.ignoreCodeFontSize** (QString): `true` **MainWindow/noteTextView.rtl** (QString): `false` **MainWindow/noteTextView.underline** (QString): `true` **MainWindow/noteTextView.useEditorStyles** (QString): `true` **MainWindow/noteTextView.useInternalExportStyling** (QString): `true` **MainWindow/showNotesFromAllNoteSubFolders** (QString): `false` **MessageBoxOverride/move-notes** (int): `16384` **NoteFolder-1/NoteTabNameList** (QStringList): `magic` **NoteFolder-1/NoteTabStickinessList** (QStringList): *empty* **NoteFolder-1/NoteTabSubFolderPathDataList** (QStringList): `Research` **NoteHistory-1** (QVariantList): `` **NoteHistoryCurrentIndex-1** (int): `10` **PasswordDialog/geometry** (QByteArray): `` **PiwikClientId** (QString): `` **ScriptRepositoryDialog/mainSplitterState** (QByteArray): `` **SearchEngineId** (int): `2` **SettingsDialog/geometry** (QByteArray): `` **SettingsDialog/mainSplitterState** (QByteArray): `` **ShowSystemTray** (QString): `false` **StartHidden** (QString): `false` **WelcomeDialog/geometry** (QByteArray): `` **acceptAllExternalModifications** (QString): `false` **allowNoteEditing** (QString): `true` **allowOnlyOneAppInstance** (QString): `true` **appMetrics/disableAppHeartbeat** (QString): `false` **appMetrics/disableTracking** (QString): `false` **appMetrics/notificationShown** (QString): `true` **automaticNoteFolderDatabaseClosing** (QString): `false` **checkSpelling** (QString): `false` **closeTodoListAfterSave** (QString): `false` **cryptoKey** (qlonglong): `` **currentNoteFolderId** (int): `1` **currentWorkspace** (QString): `initial` **cursorWidth** (int): `2` **customNoteFileExtensionList** (QStringList): *empty* **darkMode** (QString): `false` **darkModeColors** (QString): `false` **darkModeIconTheme** (QString): `false` **darkModeTrayIcon** (QString): `false` **defaultNoteFileExtension** (QString): `md` **disableAutomaticUpdateDialog** (QString): `true` **disableSavedSearchesAutoCompletion** (QString): `true` **dockWasInitializedOnce** (QString): `true` **enableNoteTree** (QString): `false` **enableSocketServer** (QString): `true` **externalEditorPath** (QString): *empty* **fullyHighlightedBlockquotes** (QString): `false` **gitCommitInterval** (int): `30` **gitExecutablePath** (QString): *empty* **gitLogCommand** (QString): *empty* **guiFirstRunInit** (QString): `true` **ignoreAllExternalModifications** (QString): `false` **ignoreAllExternalNoteFolderChanges** (QString): `false` **ignoreNoteSubFolders** (QString): `^\.` **imageScaleDown** (QString): `false` **imageScaleDownMaximumHeight** (int): `1024` **imageScaleDownMaximumWidth** (int): `1024` **initialLayoutIdentifier** (QString): `full` **insertTimeFormat** (QString): *empty* **interfaceFontSize** (int): `11` **interfaceLanguage** (QString): *empty* **interfaceStyle** (QString): `Windows` **internalIconTheme** (QString): `false` **itemHeight** (int): `15` **legacyLinking** (QString): `false` **localTrash/autoCleanupDays** (int): `30` **localTrash/autoCleanupEnabled** (QString): `true` **localTrash/supportEnabled** (QString): `true` **markdownHighlightingEnabled** (QString): `true` **navigationPanelHideSearch** (QString): `false` **networking/ignoreSSLErrors** (QString): `true` **networking/proxyType** (int): `2` **newNoteAskHeadline** (QString): `false` **noteEditIsCentralWidget** (QString): `true` **noteListPreview** (QString): `false` **noteSaveIntervalTime** (int): `10` **noteSubfoldersPanelDisplayAsFullTree** (QString): `true` **noteSubfoldersPanelHideSearch** (QString): `false` **noteSubfoldersPanelOrder** (int): `0` **noteSubfoldersPanelShowFullPath** (QString): `false` **noteSubfoldersPanelShowNotesRecursively** (QString): `false` **noteSubfoldersPanelShowRootFolderName** (QString): `true` **noteSubfoldersPanelSort** (int): `0` **notesPanelOrder** (int): `0` **notesPanelSort** (int): `1` **notesPath** (QString): `C:/Users/erich/Google Drive/_Notes` **notifyAllExternalModifications** (QString): `false` **overrideInterfaceFontSize** (QString): `false` **ownCloud/supportEnabled** (QString): `false` **ownCloud/todoCalendarBackend** (int): `3` **ownCloud/todoCalendarCalDAVPassword** (QString): `` **ownCloud/todoCalendarCalDAVServerUrl** (QString): *empty* **ownCloud/todoCalendarCalDAVUsername** (QString): *empty* **ownCloud/todoCalendarCloudConnectionId** (int): `1` **ownCloud/todoCalendarDisplayNameList** (QStringList): *empty* **ownCloud/todoCalendarEnabledList** (QStringList): *empty* **ownCloud/todoCalendarEnabledUrlList** (QStringList): *empty* **ownCloud/todoCalendarUrlList** (QStringList): *empty* **ownCloudInfo/appIsValid** (QString): `false` **ownCloudInfo/connectionErrorMessage** (QString): *empty* **ownCloudInfo/notesPathExistsText** (QString): *empty* **ownCloudInfo/serverVersion** (QString): *empty* **restoreCursorPosition** (QString): `true` **restoreLastNoteAtStartup** (QString): `true` **restoreNoteTabs** (QString): `true` **savedSearches/noteFolder-1** (QStringList): `Note 2020-10-24T23.40.11` **showMatches** (QString): `true` **showMenuBar** (QString): `true` **showStatusBar** (QString): `false` **systemIconTheme** (QString): `false` **taggingShowNotesRecursively** (QString): `false` **tagsPanelHideNoteCount** (QString): `false` **tagsPanelHideSearch** (QString): `false` **tagsPanelOrder** (int): `0` **tagsPanelSort** (int): `0` **todoCalendarSupport** (QString): `true` **toolbar/1/items** (QStringList): `action_New_note, action_Find_note, action_Remove_note, action_Open_note_in_external_editor, actionShow_local_trash, actionAllow_note_editing, , action_Back_in_note_history, action_Forward_in_note_history, , action_Find_text_in_note, actionReplace_in_current_note, , actionShow_versions, actionShow_trash, actionShare_note, , actionOpen_List` **toolbar/1/name** (QString): `mainToolBar` **toolbar/1/title** (QString): `main toolbar` **toolbar/2/items** (QStringList): `actionFormat_text_bold, actionFormat_text_italic, actionStrike_out_text, actionInsert_code_block, actionInsert_block_quote` **toolbar/2/name** (QString): `formattingToolbar` **toolbar/2/title** (QString): `formatting toolbar` **toolbar/3/items** (QStringList): `actionInsert_Link_to_note, actionInsert_image, actionInsert_current_time` **toolbar/3/name** (QString): `insertingToolbar` **toolbar/3/title** (QString): `inserting toolbar` **toolbar/4/items** (QStringList): `action_Encrypt_note, actionEdit_encrypted_note, actionDecrypt_note` **toolbar/4/name** (QString): `encryptionToolbar` **toolbar/4/title** (QString): `encryption toolbar` **toolbar/5/items** (QStringList): `actionWorkspaceComboBox, actionStore_as_new_workspace, actionRemove_current_workspace, actionRename_current_workspace, actionSwitch_to_previous_workspace, actionUnlock_panels, , actionToggle_distraction_free_mode, action_Increase_note_text_size, action_Decrease_note_text_size, action_Reset_note_text_size` **toolbar/5/name** (QString): `windowToolbar` **toolbar/5/title** (QString): `window toolbar` **toolbar/6/items** (QStringList): `action_Quit` **toolbar/6/name** (QString): `quitToolbar` **toolbar/6/title** (QString): `quit toolbar` **toolbar/size** (int): `6` **useNoteFolderButtons** (QString): `false` **useUNIXNewline** (QString): `false` **webSocketServerService/bookmarksNoteName** (QString): `Bookmarks` **webSocketServerService/bookmarksTag** (QString): `bookmarks` **webSocketServerService/port** (int): `22222` **webSocketServerService/token** (QString): `GpZYMPMQ` **workspace-initial/name** (QString): `Full` **workspace-initial/noteSubFolderDockWidgetVisible** (QString): `true` **workspace-initial/windowState** (QByteArray): `` **workspaces** (QStringList): `initial` ## System environment **ALLUSERSPROFILE**: `C:\ProgramData` **APPDATA**: `C:\Users\erich\AppData\Roaming` **ChocolateyInstall**: `C:\ProgramData\chocolatey` **ChocolateyLastPathUpdate**: `132480724750108399` **CommonProgramFiles**: `C:\Program Files\Common Files` **CommonProgramFiles(x86)**: `C:\Program Files (x86)\Common Files` **CommonProgramW6432**: `C:\Program Files\Common Files` **COMPUTERNAME**: `LAPTOP-PEDQOAQ0` **ComSpec**: `C:\WINDOWS\system32\cmd.exe` **C_EM64T_REDIST11**: `C:\Program Files (x86)\Common Files\Intel\Shared Files\cpp\` **DriverData**: `C:\Windows\System32\Drivers\DriverData` **FPS_BROWSER_APP_PROFILE_STRING**: `Internet Explorer` **FPS_BROWSER_USER_PROFILE_STRING**: `Default` **HOMEDRIVE**: `C:` **HOMEPATH**: `\Users\erich` **JAVA_HOME**: `C:\Program Files\AdoptOpenJDK\jdk-14.0.2.12-openj9` **JAVA_HOME-fx**: `C:\Program Files\AdoptOpenJDK\jdkfx11\` **JAVA_HOME_11**: `C:\Program Files\AdoptOpenJDK\jdk-11.0.8.10-openj9` **JAVA_HOME_14**: `C:\Program Files\AdoptOpenJDK\jdk-14.0.2.12-openj9` **JAVA_HOME_8**: `C:\Program Files\AdoptOpenJDK\jdk-8.0.265.01-openj9` **LOCALAPPDATA**: `C:\Users\erich\AppData\Local` **LOGONSERVER**: `\\LAPTOP-PEDQOAQ0` **NUMBER_OF_PROCESSORS**: `4` **OneDrive**: `C:\Users\erich\OneDrive` **OneDriveConsumer**: `C:\Users\erich\OneDrive` **OnlineServices**: `Online Services` **OS**: `Windows_NT` **Path**: `C:\Program Files\AdoptOpenJDK\jdk-14.0.2.12-openj9\bin;C:\Program Files (x86)\Common Files\Intel\Shared Files\cpp\bin\Intel64;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\ProgramData\chocolatey\bin;C:\Users\erich\AppData\Local\Microsoft\WindowsApps;C:\Users\erich\AppData\Local\atom\bin;%USERPROFILE%\AppData\Local\Microsoft\WindowsApps;` **PATHEXT**: `.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC` **PATH_TO_FX**: `C:\Program Files\AdoptOpenJDK\javafx-sdk-14.0.2.1\lib` **PATH_TO_FX_MODS**: `C:\Program Files\AdoptOpenJDK\javafx-jmods-14.0.2.1` **platformcode**: `KV` **PROCESSOR_ARCHITECTURE**: `AMD64` **PROCESSOR_IDENTIFIER**: `Intel64 Family 6 Model 142 Stepping 12, GenuineIntel` **PROCESSOR_LEVEL**: `6` **PROCESSOR_REVISION**: `8e0c` **ProgramData**: `C:\ProgramData` **ProgramFiles**: `C:\Program Files` **ProgramFiles(x86)**: `C:\Program Files (x86)` **ProgramW6432**: `C:\Program Files` **PSModulePath**: `C:\Program Files\WindowsPowerShell\Modules;C:\WINDOWS\system32\WindowsPowerShell\v1.0\Modules` **PUBLIC**: `C:\Users\Public` **RegionCode**: `NA` **SESSIONNAME**: `Console` **SystemDrive**: `C:` **SystemRoot**: `C:\WINDOWS` **TEMP**: `C:\Users\erich\AppData\Local\Temp` **TMP**: `C:\Users\erich\AppData\Local\Temp` **USERDOMAIN**: `LAPTOP-PEDQOAQ0` **USERDOMAIN_ROAMINGPROFILE**: `LAPTOP-PEDQOAQ0` **USERNAME**: `erich` **USERPROFILE**: `C:\Users\erich` **VBOX_MSI_INSTALL_PATH**: `C:\Program Files\Oracle\VirtualBox\` **windir**: `C:\WINDOWS`

Relevant log output in the Log panel

None.

pbek commented 3 years ago

Issue assistant doesn't work, so I post manually?

What did not work? Can you please post an issue if it doesn't work.

Windows 10 Settings > Ease of Access > Text cursor [Vision] > Turn on text cursor indicator [enabled]

Phew, I've never seen that. I don't know if or in what way this Windows-Features supports a QPlainTextEdit or how to get around its misbehavior. Does it work if you disable markdown highlighting in the Editor settings?

@Waqar144, have you seen this before?

pbek commented 3 years ago

@skaviouz, it would be interesting if you also get this issue with https://github.com/pbek/qmarkdowntextedit/ (if you are keen to build it yourself).

Waqar144 commented 3 years ago

Definitely reproducible on Win10. Not sure if it's us, it's probably something related to Qt -> Windows

@pbek do you have a windows machine?

pbek commented 3 years ago

do you have a windows machine?

not currently

pbek commented 3 years ago

Windows 10 Settings > Ease of Access > Text cursor [Vision] > Turn on text cursor indicator [enabled]

I couldn't find that setting anywhere in my Windows 10 (home edition). I searched for every part of your settings steps...

Waqar144 commented 3 years ago

Windows 10 Settings > Ease of Access > Text cursor [Vision] > Turn on text cursor indicator [enabled]

I couldn't find that setting anywhere in my Windows 10 (home edition). I searched for every part of your settings steps...

Its a relatively new feature I think so you may have to update before

pbek commented 3 years ago

My Windows should be uptodate and having a "Home edition" those updates should even be installed earlier than with the "Pro edition" (afaik Microsoft is "testing" their updates with Home users).

github-actions[bot] commented 3 years ago

This issue is stale because it has been open for 30 days with no activity.

github-actions[bot] commented 3 years ago

This issue was closed because it has been inactive for 14 days since being marked as stale.