Differences between revisions 3 and 9 (spanning 6 versions)
Revision 3 as of 2008-12-25 09:42:31
Size: 820
Editor: KaiJaeger
Comment:
Revision 9 as of 2010-01-13 18:12:13
Size: 3300
Editor: KaiJaeger
Comment: Syntaxt highlighting added
Deletions are marked like this. Additions are marked like this.
Line 2: Line 2:

<<TableOfContents>>

== Overview ==
Line 14: Line 19:
 * Comes superb merging features  * Comes with superb merging features
Line 20: Line 25:
There is a short document available that makes it easy to configure CompareIt for usage from APL. == Configuration ==
Line 22: Line 27:
Download: [[attachment:Config_CompareIt_For_Dyalog.pdf]] === Fonts ===

First thing to do is to let CompareIt! use an appropriate APL font. If you use Dyalog 12 Unicode or better, the "APL385 Unicode" font is the right one. If you are using Version 12 Classic, or an older version of Dyalog, either "Dyalog Std" or "Dyalog Alt" is the right choice.

If you use APLX, go for "APLX Upright".

But what if you got to deal with different versions of APL? There is good news: you can specify two fonts and toggle between them with Ctrl+F12!

To tell CompareIt! which font to use select from the "Options" menu the "Options" command, then click on "Edit" in the left part of the upcoming dialog box.

Here you see what needs to be changed:

{{attachment:compareit.gif}}

=== Tabs ===

Make sure that the check box "Save spaces, no tabs" is ticked - by default it is '''not'''! This prevents CompareIt! from inserting tabs into APL code which APL would not appreciate.

== APL Syntax ==

CompareIt! allows the definition of custom syntax. That allows you to hightlight APL syntax. You don't need to compile the definition file, it's [[attachment:APL.chl||ready for download]]. This file needs to go into the "Syntax" folder of the "CompareIt! folder in C:\Program Files or whatever that is on your machine.

These are the steps to tell CompareIt! to make use of that syntax definition script:

 1. Select "Options" from the "Options" menu.
 1. Click "File Filters"
 1. If there is no "APL scripts" in the list, click the "Add" button
 1. In the "Name" field, type a description for the file (APL scripts?!)
 1. In the "Mask" field, define one or more file masks. *.dyalog would make sense for Dyalog APL, for example.
 1. Select "Custom" from the "Syntaxt" drop-down list.
 1. Browse to the location of the APL.chl file.

{{attachment:compareit2.png}}

Of course CompareIt! will make use of the syntax definition file "APL.chl" only for those files that match your "Mask" definition.

== Calling CompareIt! from APL ==

You might find it useful to call CompareIt! from APL. You need to know where the executable is located. No problem on your own machine, but if you switch machines, things are different. Make this independent by asking the Windows Registry for its location. The key is:
{{{
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Compare It!_is1\InstallLocation
}}}

Note that this will work only if during the installation process the "use Windows Registry" options was checked since otherwise CompareIt! won't write anything into the Windows Registry.

CompareIt!

Overview

CompareIt! has a number of features that makes it a perfect tool for being used from APL:

  • Supports ASCII as well as UTF8 files
  • Supports two fonts, for example a non-Unicode APL font and a Unicode APL font
  • Can be called with several command line parameters which makes it handy to run CompareIt! from within APL

  • Can be integrated into TotalCommander and SubVersion

  • Allows editing the files to be compared
  • Comes with superb merging features

Furthermore, it is stable and cheap, and the support offered by Igor Green is outstanding.

You can download and try CompareIt! from http://www.grigsoft.com/

Configuration

Fonts

First thing to do is to let CompareIt! use an appropriate APL font. If you use Dyalog 12 Unicode or better, the "APL385 Unicode" font is the right one. If you are using Version 12 Classic, or an older version of Dyalog, either "Dyalog Std" or "Dyalog Alt" is the right choice.

If you use APLX, go for "APLX Upright".

But what if you got to deal with different versions of APL? There is good news: you can specify two fonts and toggle between them with Ctrl+F12!

To tell CompareIt! which font to use select from the "Options" menu the "Options" command, then click on "Edit" in the left part of the upcoming dialog box.

Here you see what needs to be changed:

compareit.gif

Tabs

Make sure that the check box "Save spaces, no tabs" is ticked - by default it is not! This prevents CompareIt! from inserting tabs into APL code which APL would not appreciate.

APL Syntax

CompareIt! allows the definition of custom syntax. That allows you to hightlight APL syntax. You don't need to compile the definition file, it's APL.chl. This file needs to go into the "Syntax" folder of the "CompareIt! folder in C:\Program Files or whatever that is on your machine.

These are the steps to tell CompareIt! to make use of that syntax definition script:

  1. Select "Options" from the "Options" menu.
  2. Click "File Filters"
  3. If there is no "APL scripts" in the list, click the "Add" button
  4. In the "Name" field, type a description for the file (APL scripts?!)
  5. In the "Mask" field, define one or more file masks. *.dyalog would make sense for Dyalog APL, for example.
  6. Select "Custom" from the "Syntaxt" drop-down list.
  7. Browse to the location of the APL.chl file.

Of course CompareIt! will make use of the syntax definition file "APL.chl" only for those files that match your "Mask" definition.

Calling CompareIt! from APL

You might find it useful to call CompareIt! from APL. You need to know where the executable is located. No problem on your own machine, but if you switch machines, things are different. Make this independent by asking the Windows Registry for its location. The key is:

HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\Compare It!_is1\InstallLocation

Note that this will work only if during the installation process the "use Windows Registry" options was checked since otherwise CompareIt! won't write anything into the Windows Registry.

CompareIt (last edited 2017-02-16 19:33:22 by KaiJaeger)