View Issue Details

IDProjectCategoryView StatusLast Update
0026803Open CASCADEOCCT:DRAWpublic2016-11-11 17:05
ReporterssvAssigned Toabv 
PrioritynormalSeveritytweak 
Status closedResolutionno change required 
PlatformLinuxOSDebian 6.0 
Summary0026803: Not possible to use Up arrow in DRAW on Linux
DescriptionIt is convenient to use Up key to get back the previously invoked commands in Draw. This is a standard behavior which does not work on Linux OS. It was tested on:

Debian 6, 7
OpenSUSE 13.2
Ubuntu 14.04 lts
OS X
TagsNo tags attached.
Test case number

Activities

msv

2016-10-25 13:01

developer   ~0059076

This is not connected to Draw. It depends on abilities of used console application. E.g., if you use a shell from Emacs, you are always able to repeat last command with Ctrl-UpArrow key stroke.

msv

2016-10-25 13:03

developer   ~0059077

Dear Sergey, if you agree with the above post I propose to close this bug.

ssv

2016-10-25 13:18

developer   ~0059078

I do not like the idea to close the issue as it originates from the real customer who spends full working day in the console mode.

! Working in Draw from Linux console is painful !

This issue breaks your user's habit. For me, it deserves deeper investigation.

abv

2016-11-09 10:48

manager   ~0060072

I am going to check this in my environment (Ubuntu under Virtual Box)

abv

2016-11-10 06:49

manager   ~0060156

Sergey, as Mikhail explained, this behavior is "standard" only for some shells such as Linux terminals, and some terminals do this only for their own commands, not intercepting input of command line applications (and DRAW is a separate command-line app, it is not part of the terminal!). Note that some terminals do provide filtering of user input before passing to console app, and in these you can have command history. This applies to Emacs on Linux (when running DRAW within its shell buffer -- as we do most of the time) and command prompt on Windows.

Thus in general case the support for the command line history needs to be provided by each particular console application. DRAW is based on Tcl, and tclsh launched in Linux terminal has the same issue (does not provide command history by arrows).

Instead of implementing our own support for command history in DRAW, we can use rlwrap utility, as suggested here: http://stackoverflow.com/questions/3041530/how-to-get-command-history-by-cursor-key-in-linux-tclsh

I have tried this and it works. Just install this utility and edit draw.sh file replacing the last line by this one:

rlwrap `which DRAWEXE`

Please consider if this explanation is sufficient for your case, or it makes sense to embed this work-around into scripts deployed with OCCT.

ssv

2016-11-11 16:57

developer   ~0060247

Andrey, thanks for the explanation. So we can close the issue finally.

Issue History

Date Modified Username Field Change
2015-10-23 15:08 ssv New Issue
2015-10-23 15:08 ssv Assigned To => mkv
2015-10-23 15:26 mkv Assigned To mkv => apn
2015-10-23 15:26 mkv Status new => assigned
2015-12-18 15:17 abv Target Version 7.0.0 => 7.1.0
2016-10-25 13:01 msv Note Added: 0059076
2016-10-25 13:03 msv Note Added: 0059077
2016-10-25 13:03 msv Assigned To apn => ssv
2016-10-25 13:03 msv Status assigned => feedback
2016-10-25 13:18 ssv Note Added: 0059078
2016-11-09 10:48 abv Assigned To ssv => abv
2016-11-09 10:48 abv Note Added: 0060072
2016-11-10 06:33 abv Assigned To abv => ssv
2016-11-10 06:49 abv Note Added: 0060156
2016-11-10 08:46 kgv Description Updated
2016-11-11 16:57 ssv Note Added: 0060247
2016-11-11 16:57 ssv Assigned To ssv => abv
2016-11-11 17:05 abv Severity major => tweak
2016-11-11 17:05 abv Status feedback => closed
2016-11-11 17:05 abv Resolution open => no change required
2016-11-11 17:05 abv Target Version 7.1.0 =>