Opened 3 years ago

Closed 3 years ago

#31 closed defect (fixed)

nepmd 1.22: command "key" does not properly work when invoked from commandline

Reported by: erdmann Owned by: Andreas Schnellbacher
Priority: major Milestone: Unsorted
Component: Other Version: 1.22
Keywords: Cc:

Description (last modified by Andreas Schnellbacher)

My inention is to open a file from a command line, select a specific line and "mark" that line by invoking alt-L (which marks the current line).

I use this to open file "somefile.cod", select line 1234 and mark the line:

epm.exe "somefile.cod" 'mc /postme 1234 /postme key 1 a+l'

This works fine with the original epm.exe but fails with nepmd. I'd prefer if nepmd supported all the original epm commands as they were specified to work.

Change History (3)

comment:1 by Andreas Schnellbacher, 3 years ago

Description: modified (diff)
Owner: set to Andreas Schnellbacher
Status: newaccepted

This is a regression of moving from WM_CHAR to accelerator keys to allow for more key defs and to ease making them. The involved statements, procs and cmds never supported them. They work only with WM_CHAR keys.

Since the NEPMD change to accel keys, WM_CHAR keys are only used for single keys (and internally for those virtual keys that are on the keypad). I've overlooked that executekey etc. works also for virtual WM_CHAR keys. BTW: There exist DoKey and LoopKey, too. They all use executekey. Most likely I should also add a replacement for the lastkey statement.

Until this will be fixed, use a simple change:

epm.exe "somefile.cod" 'mc /postme 1234 /postme MarkLine'

BTW: If you want to mark several lines, use the DoCmd command and move the cursor down:

epm.exe "somefile.cod" 'mc /postme 1234 /postme MarkLine /postme DoCmd 2 Down /postme MarkLine'

or easier:

epm.exe "somefile.cod" 'postme mc /1234 /MarkLine /DoCmd 2 Down /MarkLine'
Last edited 3 years ago by Andreas Schnellbacher (previous) (diff)

comment:2 by Andreas Schnellbacher, 3 years ago

Version: 1.211.22

comment:3 by Andreas Schnellbacher, 3 years ago

Resolution: fixed
Status: acceptedclosed

Fixed by changeset r4537.

Note: See TracTickets for help on using tickets.