Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Topics - alex

Pages: 1 ... 3 4 [5]
FAQ / Where my HippoEDIT configuration stored?
« on: January 02, 2009, 12:54:08 pm »
HippoEDIT sotres configuration in different files. All paths are default and relative to HippoEDIT user directory. Location of the HippoEDIT user data directory depends on installation type you have selected: for portable it equals installation directory, for Current user should be in %AppData%\HippoEDIT for current user, for all users should be in All Users\Application Data\HippoEDIT:
  • Hippoedit.config - stores global IDE settings
  • workspaces\default.hewsp - Default workspace. Window positions and states, open files, recent files, input history etc for HE started standalone
  • workspaces\viewer.hewsp - Viewer workspace. Same as default.hewsp but for cases when HE started by double click from explorer (if --workspace=viewer passed in command line)
  • data\settings.xml - editor settings
  • data\syntax\..._spec.xml + ..._user.xml  - specification and user files for separated syntaxes
  • data\keymaps\keymap_default.xml - default keyboard layout

Usually if you are asked to send configuration files, you need to send:
Hippoedit.config, workspaces\default.hewsp and data\settings.xml. Sometimes, if problem occurs in context of some specific syntax, it is better to to send also data\syntax\%you_syntax%_spec.xml + %you_syntax%_user.xml.

It is not possible to copy license.dat from one PC to another one. You need to re-register (enter your license key) in second machine too.
The only way to avoid this, if you initially install HE on flash (remote) drive. In this case license.dat would be bound to it.

FAQ / How to get more information about the error
« on: January 02, 2009, 12:35:13 pm »
In some cases when it is not possible to easy reproduce crash/hanging or it is unregular or happens only on your machine, it is possible to get more information about the error using debug information for HippoEDIT (HE) and special tools.

So what to do if you are willing to help, but dont know how.

Get HE installation with debug symbols. It can be found here: - 9 Mb (replace 140 to actual version, fex 1.44 -> 144 or 1.54 -> 145 or 1.50 -> 150). If file does not exist on server or you coud not reproduce the error with this installation (it is not always up to date), then ask on here to update it.

There are two ways to get call stack of the error.

Process Explorer. Easy way, but less informative
  • Download Process Explorer from here (very good tool, like extended Task Manager).
  • Unpack, start.
  • Run HE from installation with debug symbols and try to reproduce the crash.
  • After you get crash message box, go to Process Explorer, find process Hippoedit.exe, double click on it.
  • In "Properties" window find tab "Threads", select thread with Hippoedit.exe in name and click on button Stack.
  • Copy stack trace and send it to us. Probably it would not be corrupted and can help us to find starting point for problem...

Microsoft Debugger. Harder way, but more informative
You can use free Microsoft Debugger (WinDBG) to create special dump with information about the call stack of the error.
  • Install Debugging tools from Microsoft website (very fast, requires no validation etc) - 17 Mb on the machine where the HippoEDIT has to be analyzed.
  • Download this file into the Debugging Tools installation folder (C:\Program Files\Debugging Tools for Windows).
  • Set environment variable to load windows symbols (explanation how to set an environment variable can be found here):
    _NT_SYMBOL_PATH= symsrv*symsrv.dll*c:\pdbs*
  • Then start HippoEDIT and reproduce the scenario or work with HippoEDIT if not reproducible.
  • BEFORE the exception occurs you have to do the following:
  • Enter in the Start/Run dialog "cmd.exe"
  • Then in the command prompt run the following command:
    cd "C:\Program Files\Debugging Tools for Windows (x86)"
    adplus.vbs -c adplus_cfg.txt
  • You will get the following popup:

    "WScript is currently your default script processor... Would you like to register CScript..."
    => choose "Yes"

    "Successfully registered CStript.exe ... The change back type 'wscript.exe //h:wscript" in a command shell"
    => do this later after finishing the analysis

    "AdPlus is now running in CRASH mode... please check the ... directory"
    => choose "OK"
  • Now reproduce the crash. Check inside this directory whether a "Crash*" sub directory has been created:
    C:\program Files\Debugging Tools for Windows (x86)

    ...for Windows\Crash_Mode__Date_01-17-2008__Time_11-11-1515

    Take directory with latest time.
  • Then please send us the zipped directory's content with description how to reproduce the error if possible.
  • Copy of this description together with attached file can be downloaded here.
  • Files to be sent is simple log text files and contain no confidential information.

FAQ / How to set an Environment variable
« on: January 02, 2009, 12:21:26 pm »
Open System in Control Panel.

On the Advanced tab, click Environment Variables, then click the name of the user variable or system variable you want to change, as follows. Click:

New - to add a new variable name and value.
Edit  - to change a current variable name and value.
Delete  - to remove a variable name and value.

If you are not logged on as administrator to the local computer, the only environment variables you can change are user variables.

FAQ / How to run associated application?
« on: December 04, 2008, 12:00:47 pm »
If you want to run associated application for your document (the same that would happen if you after double click on this document in Windows Explorer) you can do it with a tool feature.

Create new tool, and then do such not obvious thisng ;):
Instead of Arguments field, place %FileName% to Command field in the Tools Options dialog.
This should be done in case when you want to run associated application for your current document.
But the same is true for %InteractiveFile% and %MainFilePath%.

FAQ / Can HippoEDIT run portable?
« on: November 07, 2008, 01:51:40 am »
HippoEDIT versions 1.3x:
Mostly all editor settings are stored in XML files. Location of settings files can be customized in Tools->Options->General. By default it is HippoEDIT folder (hippoedit.config) and data folder (all xml files). Only windows positions, state theme and some other GUI properties are stored in the registry.

HippoEDIT versions from 1.40:
Everything is stored in xml files. Also all GUI states now stored in workspaces subfolder in HippoEDIT directory.

Only one limitation: location of data files is still stored in the registry. But this should be only interested to you if you have changed default location.

HippoEDIT also uses Windows %Temp% folder to store buffered service data between sessions.

Syntax Files / Adding new Language Syntax
« on: October 29, 2008, 01:10:00 am »
INFO: Keep this thread clean please
For discussing or questions please use "Adding new Language Syntax - Discuss thread" >click<


I would try to write some instruction here, based on your questions and then would move the thread to FAQ brunch.

The definition of the programming language (syntax) in HippoEDIT is based on two files: {lang_name}_spec.xml and  {lang_name}_user.xml. Names of the file is not important – definition recognized by XML header. {lang_name}_spec.xml contains general definition of the syntax and is obligatory. {lang_name}_user.xml contains definition of the user specific settings for language (such as code templates, programming language specific tools, language help urls etc.) and is optional. Definition files should be placed in directory defined in Tools -> Options -> General -> Settings Path. By default this is {HippoEDIT_InstallDir}\data\syntax.
To create your own syntax I would suggest to search some existing schema for language similar to one you want to have and copy + rename files.
Then open new files and search for something similar to this:
Code: XML
  1. <SYNTAX id="asm" name="ASM" inherit="def_source" inherit_url="defsource_spec.xml">
  • id (any string, preferable low case, without spaces and symbol : ) – unique id of the language (obligatory)
  • name (any string) – description of the language that would be used in UI
  • inherit (any id) – name of base (parent) schema. New schema would inherit all settings, styles of   parent. Normally you need to inherit from def or def_text or def_source. These schemes contain base definition for styles, without them a lot of functionality would not be available.
  • inhertit_url (file path, relative or absolute) – name of parent schema file. Used only fir navigation between schemes when opened in browser (optional).
After creating of the definition files and copying them into {Data} folder, HippoEDIT should load definitions and display them in Available Languages list (Tools->Options->Available Languages).
Code: XML
This node contains base settings for syntax (as file pattern, braces list, case sensitive flag etc).
Operators - set of single symbols, which will be treated as operator symbols by HE and displayed with operator style, if it is defined/inherited for current schema. Operator style is one of special HE known styles (as comments fex).
Delimiters - set of single symbols, which used to determine delimiter symbol (symbol which stops/starts word). You can place here only that symbols which do not come to operators or OpenClose node. If they will intersect, it is not problem. But if some of the delimiter symbols will be forgotten, HE will "stop" on it during next word navigation, for example.



This node contains Scopes that used for parsing outlining (folding). Inheritable from parent.

Code: XML
  1. <Scope>
This node described specific scope. Scope should have one [1] open, can be more than one [1.n] close tags and none or more middle tags [0..n].
Code: XML
  1. <Scope open="Class" close="End Class" has_name="true" separator="true"/>
  • open (any string) – is open tag
  • close (any string) – is close tag
  • has_name (true|false|0|1) – indicates that name of the scope follows open tag
  • separator (true|false|0|1) – draw separator after close tag (if enabled in editor settings)
  • strict (true|false|0|1) – flag tells HE to not take seriously missing close text for this scope. So you would not get a error displayed for open tag. The attribute also used for better solving of outlining constructions (strict scopes have higher priority than non-strict ).


Code: XML
  1. <LABELS>
  2.    <Label group="Subroutine" match="\&lt;(sub|function)[\s\[]+(\w+)[\s\]]*(\([^)]*\))" name="\2" descr="\1 \2 \3" image="8" scope="1">
  3.       <Image if="\1" equal="sub" value="8"/>
  4.    </Label>
  5.    <Label group="Class" match="\&lt;(public|private)?\s+class\s+(\w+)\s*" name="\2" descr="Class \2" image="4" scope="1">
  6.       <SubImage if="\1" equal="public" value="1"/>
  7.    </Label>
  8. </LABELS>

Labels give you a way fo quick navigation inside the document with Navigation Bar (can be also called as Function List). It can be as a method or function definition, as include definition. Generally it can be any part of the code you want to refer.
Labels are described with help of regular expression.
HippoEDIT uses BOOST regular expression engine, which use perl regular expression syntax.
For testing of the label definition I am using RegexLib service.
  • group (any string) - group of the label, currently not used, but would be used later for displaying labels in Function List window grouped by label name
  • match (any valid regular expression), obligatory - regular expression describing the label. Expression can be multi line and greedy. You can use sub matches (grouping) for later referring.
  • name (any string) - any string describing found label. name is displayed in left filtered list in Navigation Bar. You can refer to results of the match using regular expression replace tags as \0 complete match, \1 - firts group, \2 second and so on...
  • descr (any string) - wider description of found label. descr is displayed in right (description) field in Navigation Bar. You can refer to results of the match using regular expression replace tags as \0 complete match, \1 - firts group, \2 second and so on...
  • descr_match (any valid regular expression), obligatory - additional regular expression for better resolving of the description. Applied to result of the match. If exist, results of descr_match would be used for description back references.
  • image (enumeration from 5 till 20, none=default=0) - image associated with label. Image is displayed as in left list of Navigation Bar as in right description field.
  • sub_image (enumeration from 2 till 4, none=default=0) - sub image associated with label (image drawn on top of main image). Usually used for visualization of label visibility (public, protected, private).
  • scope (0|1|2) - defines relation of the label to any scope. 0 - not related to scope, 1 - label includes relevant scope start, 2 - scope includes relevant scope end. If label is related to scope (1|2) HippoEDIT would try to find appropriate scope and associate label with it. Then you would see label description as name of the scope while navigating in Navigation Bar and in Scroll Info Tip.
  • navigation (true|false, default = true) - if set, then label would not be shown in Navigation Bar, but would be used in Smart Navigate and when Go button pressed in Navigation Bar. For example to navigate to include file.
  • navigation (true|false, default = true) - if set, then label would not be shown in Navigation Bar, but would be used in Smart Navigate and when Go button pressed in Navigation Bar. For example to navigate to include file.

In addition to listed before properties, you can have some overriding of the label properties, depending on regular expression match.

Skip condition:
Code: XML
  1. <Skip if="\2" equal="if"/>
If you want to skip some labels depending on result of the match, you can use a Skip Condition defined inside of Label node.
  • if (some regular expression string with back references to match) - regular expression with back references to match which would be compared to equal
  • equal - string to compare with result of regular expression replace from attribute if
If if equals to equal the label would be skipped.

Image/SubImage condition:
Code: XML
  1. <Image if="\1" equal="sub" value="8"/>
  2. <SubImage if="\1" equal="private" value="3"/>
If you want to adopt image or subimage based on result of label match, you can useImage/SubImage Condition defined inside of Label node.
  • if (some regex string with back references to match) - regular expression with back references to match which would be compared to equal
  • equal - string to compare with result of regular expression replace from attribute if
  • value - enumeration value of the image or sub image
If if equals to equal the label would have image or sub image defined in value.

To restrict label for some style, you can also use Containers node inside Label node.
Code: XML
  1. <Containers open="preprocessor"/>

CONTAINERS - how to use

The logic is following:
1) You have styles. Styles are described by Blocks, Keywords, and Words conditions and applied to some interval of the text (text block).
2) Styles can be referred by style id. If id is not defined HE uses name attribute.
3) When you define container (or containers) for Scope or another schema object, you allow this Scope, Style or Label etc to be recognized only in the style specified by container id.

For example this mean:
Code: XML
  1. <Scope open="{" close="}">
  2.    <containers open="test_container_name"/>
  3. </Scope>
Scope with open tag "{" allowed only in the style "test_container_name". If it would be found in some other style, it would be skipped. If you do not specify containers, HE assumes that this object (scope, style or label) allowed only in normal style (style with id = normal, defined in def_spec.xml).

For objects as Scope and Style you can define containers as for open part, as for close part (for scopes also for middle part). For example CSS block in HTML can be started in normal style of HTML code and can be closed inside CSS normal or comment style.
Code: XML
  1. <Containers>
  2.    <Close id="css:normal"/>
  3.    <Close id="css:comment"/>
  4. </Containers>
If you do not define open container, it would be normal style of current language.

If you want to refer to a style from another syntax schema, you can do this as well, by giving syntax id before style id separated with ":"  :
Code: XML
  1. <Style id="style" name="CSS" include="css:normal" ...
This is including of the CSS block in HTML syntax schema.


FAQ / Best font for source code editing
« on: September 22, 2008, 09:38:06 pm »
There are several reasons to use monospaced font for source code editing.

First reason: only with monospaced font, indented text would be placed on same horizontal level. Even if indented block starts not from line start.
Second reason: block/column selection works well only with monospaced font.

Here are some monospaced fonts that fit best for code editing:

Courier New - most standard, installed on every Windows system, has rather big Unicode char set (on XP and higher)
Microsoft Consolas – visually better then Courier New, installed by default on Vista and higher, has very big Unicode char set.
Inconsolata – perfect font for source editing, small, distributed with Open Font License, but bold style, for my taste is too thick. Also, has only European char set.
Dina - another free programmers font. User comment: In my HE it looks like that - cool and solid by Arthur.

In the HippoEDIT, font can be adjusted for every syntax, but by default all fonts’ settings are inherited from Default syntax schema (only Plain Text overrides it by Lucida Console, to be similar to Notepad).
You can find font settings in main menu: Tools->Options->Syntax Settings->Default (or any interested syntax) ->Fonts & Colors. If Show only monospaced fonts flag is not set, then on all monospaced fonts in list would be highlighted with a color. If you want to use font from parent syntax, just select inherit from Parent Syntax Name in the list. This is first entry.

If you can suggest something better, just post here, I would update list with recommendations.

Just have found perfect article with monospaced font comparison on from Hans Dietrich. Article contains big set of monospace font examples with preview and description.

FAQ / What is Selection -> Lock ?
« on: June 29, 2008, 04:19:47 pm »
Selection. Lock - switches to the mode when selection is locked, and is not erased on mouse clicks, but could be only explicitely changed.
In this mode, for example, Replace in selection, can work.

FAQ / What is the use of Find Results windows on bottom of HippoEDIT?
« on: June 29, 2008, 04:17:36 pm »
If you do search with “Find All” or “Replace All” the results can be forwarded to one of “Find Results” windows, or to new document.

Call Find dialog (Ctrl+F) then check Result Options group.

You can capture output (messages) only of console application (without GUI) or batch file.
The flag controlling this can be found in properties page of the tool -> “Capture output”.
For tools that do not provide output, this checkbox would be disabled.

Tool properties page can be accessed or by right click in project item (if project tool) or through main menu Tools->Manage Tools->Edit.
In addition you can define output pattern that can be used for parsing results. Then you can navigate directly to file/line/pos printed by the tool by clicking on corresponding line in Output window.

FAQ / How to use together with Punto Switcher? ...
« on: June 29, 2008, 04:15:16 pm »
Too many characters are deleted on Break  :'(

A. Uncheck function “Double rate on key repeat” in Tools->Options->Formatting->Smart Helpers.
When this option enabled, some commands are speeded up when buttons pressed delayed (and then time interval between commands is small).
Such logic applied for all movement commands and backspace or delete.

Punto uses backspace commands to delete old text and continuously sends them to HippoEDIT, simulating delayed press.
That is why 2ce more characters deleted.

Pages: 1 ... 3 4 [5]