Blog
All Blog Posts | Next Post | Previous PostSwitching between sources and more in the latest TTMSFNCMemo update
Monday, April 24, 2023
With the latest iteration of the TTMSFNCMemo we have now added support for multiple sources and a file-extension/language map which is used to select the correct language based on the file-extension when loading a file in the memo.
Sources
Sources enables the user to quickly switch between different lines, whilst keeping breakpoints, cursor position,
You can simply add sources to the Sources collection in the form designer or you can use the various add source function's to quickly load a file like the example down below:
if OpenDialog1.Execute then begin source := TMSFNCMemo1.AddSourceFromFile(OpenDialog1.Files[0]); tab := TMSFNCTabSet1.AddTab(source.Name); TMSFNCMemo1.ActiveSource := tab.Index; end;
File-extension / Language mapping
Every time you load a file, the memo will check the LanguageFileExtensionMap collection if it finds a registered extension, and then set the corresponding language. Just add the file extensions you want to the collection and you're good to go. Nothing else is needed.
Ready?
Want to try out the latest version of TTMSFNCMemo? Go ahead and download TMS FNC UI Pack. Drop the TTMSFNCMemo on the form and read through the online documentation, or open the demo which can be found in the installation directory
Bradley Velghe
This blog post has not received any comments yet.
All Blog Posts | Next Post | Previous Post