code accuratepyedit now strips off any directory path prefix in the file' name before launching itbecause its original directory path may no longer be valid if it is relative instead of absolute for instancepaths of files opened manually are absolutebut file paths in pydemos' code pop ups are all relative to the example package root and would fail after chdir pyedit now correctly uses launcher tools that support command-line arguments for file mode on windows pyedit inherits fix in the underlying launchmodes module that changes forward slashes in script path names to backslashes (though this was later made moot point by stripping relative path prefixespyedit gets by with forward slashes on windows because open allows thembut some windows launch tools do not additionallyfor both code run from files and code run in memorythis version adds an update call between pop-up dialogs to ensure that later dialogs appear in all cases (the second occasionally failed to pop up in rare contextseven with these fixesrun code is useful but still not fully robust for exampleif the edited code is not run from fileit is run in-process and not spawned off in threadand so may block the gui it' also not clear how best to handle import paths and directories for files run in nonfile modeor whether this mode is worth retaining in general improve as desired unicode (internationalizedtext support finallybecause python now fully supports unicode textthis version of pyedit doestoo--it allows text of arbitrary unicode encodings and character sets to be opened and saved in filesviewed and edited in its guiand searched by its directory search utility this support is reflected in pymailgui' user interface in variety of waysopens must ask the user for an encoding (suggesting the platform defaultif one is not provided by the client application or configuration saves of new files must ask for an encoding if one is not provided by configuration display and edit must rely on the gui toolkit' own support for unicode text grep directory searches must allow for input of an encoding to apply to all files in the tree and skip files that fail to decodeas described earlier the net result is to support internationalized text which may differ from the platform' default encoding this is particularly useful for text files fetched over the internet by email or ftp ' pymailguifor exampleuses an embedded pyedit object to view text attachments of arbitrary origin and encoding the grep utility' unicode support was described earlierthe remainder of this model essentially reduces to file opens and savesas the next section describes unicode file and display model because strings are always unicode code-point strings once they are created in memoryunicode support really means supporting arbitrary encodings for text files when they are read and written recall that text can be stored in complete gui programs