Started by Gary Beene, November 07, 2013, 01:48:08 AM
0 Members and 1 Guest are viewing this topic.
' // Toggle the current bookmark CASE %IDM_TOGGLEBOOKMARK SCI_ToggleBookmark(pSed.hEdit) ' // Comment and uncomment the line just to make ' // the file dirty and force saving. SCI_BlockComment(pSed.hEdit) SCI_BlockUncomment(pSed.hEdit) EXIT FUNCTION
QuoteThe following messages are currently supported to emulate existing Windows controls, but they will be removed in future versions of Scintilla. If you use these messages you should replace them with the Scintilla equivalent.EM_SetModify(bool isModified)
QuoteCase %IDM_TOGGLEBOOKMARK SCI_ToggleBookmark(pSed.hEdit) ' // make the file dirty and force saving. SendMessage pSed.hEdit, %EM_SetModify, %True, 0 'BEENE Exit Function
QuoteCase %IDM_TOGGLEBOOKMARK SCI_ToggleBookmark(pSed.hEdit) ' // make the file dirty and force saving. SendMessage pSed.hEdit, %EM_SetModify, 1, 0 'BEENE ? Str$(SCI_GetModify(pSed.hEdit)) '<--- returns 0 Exit Function
Quote? Str$(SendMessage(pSed.hEdit, %EM_GetModify, 0, 0))
Quotescintilla-interest ›Force Dirty State?3 posts by 2 authors Gary Beene 7/26/10Is there a message I can use that is the opposite of SCI_SetSavePoint,one that will force Scintilla into a "dirty" state? Gary Beene 7/26/10Umm... I can see where that would be a problem. If I arbitrarily makeScintilla "dirty", how will the undo/redo stack know where the savepoint would be? Neil Hodgson 7/26/10gbeene:> Is there a message I can use that is the opposite of SCI_SetSavePoint,> one that will force Scintilla into a "dirty" state? No and there won't be. If you are trying to manage application level state like changingthe encoding a file will be saved in then manage that in theapplication. Neil
If SCI_GetModify(pSed.hEdit) Then
If SCI_GetModify(pSed.hEdit) or pSed.BookmarkCount Then
QuoteSince each bookmark (Ctrl-F2) adds an apostrophe to the undo stack, if I were doing lots of bookmarks, I might argue that the coding effort would be worth it.
Page created in 0.113 seconds with 22 queries.