Closed GoogleCodeExporter closed 9 years ago
Sorry for the problem and thank you very much for the detailed report! :-)
I'm also (still) working under RHEL 5 and there is unfortunately a very ancient
Emacs version installed. It was released 7 years ago! Could you please
install or compile a newer version? It will save you some hassle.
If not please comment out (like below) the paragraph in ansys-mode.el
(beginning with line 410) for a start.
;(add-to-list 'insert-pair-alist '(?\* ?\*))
;(add-to-list 'insert-pair-alist '(?\$ ?\$))
;(add-to-list 'insert-pair-alist '(?\% ?\%))
> 3. Selected the entirety of start-ansys-mode.el and did (M-x eval-region RET)
By the way, it should be enough to type
M-x load-file start-ansys-mode.el
Original comment by dieter.wilhelm@gmail.com
on 23 Feb 2012 at 3:51
Original comment by dieter.wilhelm@gmail.com
on 23 Feb 2012 at 4:12
I actually solved the immediate problem by inserting the following line before
line 410:
(defvar insert-pair-alist nil)
This gives me the same result as just commenting out the three lines.
Ansys-mode now starts without error, but it doesn't behave as expected. I'm
attaching a screenshot.
(To be precise, my buffers appear the same when I change from one version of
ansys-mode.el to the other, execute start-ansys-mode.el, and reapply M-x
ansys-mode).
Original comment by iiv...@gmail.com
on 24 Feb 2012 at 5:43
Attachments:
Thanks again for trying ansys-mode.
> (defvar insert-pair-alist nil)
OK :-)
> (To be precise, my buffers appear the same when I change from one version of
ansys-mode.el to the other, execute start-ansys-mode.el, and reapply M-x
ansys-mode).
I'm sorry, I do not get what you want to achieve and why ansys-mode isn't
behaving as expected. But I realized that also something nasty is happening.
Please have a look at the Emacs mode line. You'll see (angular) brackets
around the mode specification (here: (Ansys)) and tis is a sign that you're in
"recursive edit mode", i.e. that you're doing commands within a command. Maybe
that is the reason something unexpected is happening?
By the way, the different version of ansys-mode doesn't differ so much visually
from each other (i.e. the highlighting/fontlocking). There are new features
and the latest Ansys keywords though...
Original comment by dieter.wilhelm@gmail.com
on 24 Feb 2012 at 6:09
OK, let me be clear. I'm comparing the appearance of my fontification.mac to
the example here:
http://www.emacswiki.org/emacs/AnsysMode
There are two syntax highlighting elements missing: the *MSG block and variable
names. (It highlights the left-hand sides of assignment statements, but
doesn't catch the names of the variables when they occur later in the code.)
Also, I get the standard right-click context menu instead of the fancy one on
EmacsWiki. (Or at least I think it's the standard one... I never actually use
it.)
I did notice the brackets in the mode window, but I didn't understand what they
meant. When I get back to the office, I'll try to understand why it's going
into recursive edit mode. It sounds like it might explain why only the basic
features are loading.
Original comment by iiv...@gmail.com
on 26 Feb 2012 at 6:02
Variable names are only highlighted dynamically when you are in level 2 AND
have evaluated
(setq ansys-dynamic-highlighting-flag t)
please have a look in default_el.
And what you can see on EmacsWiki is the ripped off GTK menu and not the
RMB-menu. You'll get it with the gtk version of Emacs.
Original comment by dieter.wilhelm@gmail.com
on 27 Feb 2012 at 9:46
I made conditional test around the insert-pair-alist block which gave the error
message with Emacs21.
Original comment by dieter.wilhelm@gmail.com
on 10 Mar 2012 at 6:39
Referring to your comment 5 about the *MSG block:
The multiline highlighting is somewhat brittle, please use M-g M-g to improve
the highlighting of such a block, for me it worked in Emacs21.4
Original comment by dieter.wilhelm@gmail.com
on 16 Mar 2012 at 5:45
Thank you for the files,
First remark: In your start-ansys-mode.el you've
(add-to-list 'load-path "/home/igurin/Ansys/utility/ansys-mode")
then there is no need to for the complete path to all the .el files in
ansys-mode-ig.el. No error but just to be complete.
Second remark: please change all occurrences of
(line-number-at-pos)
with the number
1
(or some other integer) in ansys-mode-ig.el and put there an empty function
declaration
(defun assoc-string (a b c) nil)
at the beginning, then ansys-mode should start at least without an error and
most functionality -- including the autoloading -- should be preserved within
Emacs 21.4. :-)
Hope this helps & have fun with Ansys mode
Dieter
P. S. please try also the "debugging" mode, where you run the Ansys interpreter
within Emacs, you can send single lines or whole sections to the interpreter
and your are even able to check the result visually!
Original comment by dieter.wilhelm@gmail.com
on 23 Mar 2012 at 3:50
Original issue reported on code.google.com by
iiv...@gmail.com
on 22 Feb 2012 at 11:56