A problem with sessions (1.0.6):
(if some files were deleted):
active document error (active document was for example 12, but only 10 documents were opened
drpython is in chaos afterwards
so a check would be good:
if ActiveDocument > len(DrFrame.txtDocumentArray):
ActiveDocument = 0
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Save of history find/replace string:
every time, the old find strings are saved and not the newer ones:
f.write("<Find History>\n<Find>")
DrFrame.FindHistory = DrFrame.FindHistory[-DrFrame.SESSIONPREFSfindhistory:]
for x in DrFrame.FindHistory:
f.write(x + '\n\n\r\r\r\n')
f.write("</Find>\n<Replace>")
DrFrame.ReplaceHistory = DrFrame.ReplaceHistory[-DrFrame.SESSIONPREFSfindhistory:]
for x in DrFrame.ReplaceHistory:
f.write(x + '\n\n\r\r\r\n')
BTW: Shortcuts and Add to pop up is not working (I tried to bind a shortcut for "loadsession")
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Updated Sessions, and put down a minor plugin
for redirecting standard output.
A problem with sessions (1.0.6):
(if some files were deleted):
active document error (active document was for example 12, but only 10 documents were opened
drpython is in chaos afterwards
so a check would be good:
if ActiveDocument > len(DrFrame.txtDocumentArray):
ActiveDocument = 0
Sessions:
I'd like to suggest a patch:
Save of history find/replace string:
every time, the old find strings are saved and not the newer ones:
f.write("<Find History>\n<Find>")
DrFrame.FindHistory = DrFrame.FindHistory[-DrFrame.SESSIONPREFSfindhistory:]
for x in DrFrame.FindHistory:
f.write(x + '\n\n\r\r\r\n')
f.write("</Find>\n<Replace>")
DrFrame.ReplaceHistory = DrFrame.ReplaceHistory[-DrFrame.SESSIONPREFSfindhistory:]
for x in DrFrame.ReplaceHistory:
f.write(x + '\n\n\r\r\r\n')
BTW: Shortcuts and Add to pop up is not working (I tried to bind a shortcut for "loadsession")