Questions tagged [cperl-mode]

`cperl-mode` is an Emacs mode for editing Perl that expands on the functionality of `perl-mode` and provides a variety of IDE-like editing, reference, and navigation functions.

cperl-mode is an Emacs mode for editing Perl that expands on the functionality of perl-mode and provides a variety of IDE-like editing, reference, and navigation functions.

cperl-mode offers:

  • Access to local perldoc-format documentation
  • Improved syntax highlighting vs. basic perl-mode
  • A wider variety of formatting options for Perl code
  • Automatic expansions of common constructs such as if, else, and while
  • Better integration of POD documentation in Perl modules
26 questions
1
vote
2 answers

Emacs indent issue with qw keyword

I have Emacs 26.3 running on windows with cperl-mode 6.2 from the last commit of the cperl-mode repository of jrockway. I have the following configuration for Emacs : (setq-default tab-width 4) (setq-default indent-tabs-mode nil) (setq…
Lucas Lam
  • 21
  • 4
1
vote
0 answers

Distinguishing multiline strings that need indentation from those that do not

---+ BRIEF This question is about indenting multiline strings, e.g. for Perl, in emacs' cperl-mode, so that they do not break up the flow of the code. I know how to get the indentation I want, using transformations like =~ s/^[^\S\n]*\|//mhr on the…
Krazy Glew
  • 7,210
  • 2
  • 49
  • 62
1
vote
1 answer

How can I enable cperl syntax check on aquamacs?

Check syntax is in cperl menu disabled. If I try M-x cperl-check-syntax, I got error message Cannot open load file: no such file or directory, mode-compile. I found no hint on emacswiki.
Gerd
  • 2,265
  • 1
  • 27
  • 46
1
vote
1 answer

Emacs CPerl mode: bug in indent-region

I edit my Perl scripts in Emacs, using CPerl mode. But the Emacs function indent-region is broken in that mode. If I have a variable: my $num_elements; it becomes my $num_ elements; It's very annoying, especially since I am used to using…
Frank
  • 64,140
  • 93
  • 237
  • 324
1
vote
1 answer

How do I adjust cperl mode indentation of qw//?

Following on from this question, here's another bugbear. I am getting my @browsers = qw/ Firefox MSIE /; but I want my @browsers = qw/ Firefox MSIE /; What setting in cperl mode in Emacs might I…
user181548
1
vote
0 answers

Emacs cperl mode: disabling insertion of "if" etc

I've been using cperl-mode in Emacs for some time. On a new system, I've been getting a problematic behaviour: when I type something like "if", Emacs expands it into a full-blown statement, so it'll automatically give me if () { } This is really…
user1235777
  • 609
  • 7
  • 24
1
vote
1 answer

Syntax for adding/removing font-lock keywords in Emacs

Most of what I do with Emacs is in perl, and for that cperl-mode is mostly excellent; the one major annoyance is that a simple my $whatever introduction is given the property font-lock-keyword-face, which nixes the advantage of having keywords pop. …
Amory
  • 758
  • 2
  • 19
  • 31
0
votes
1 answer

emacs identation works only in terminal (-nw)

I have GNU Emacs 23.1.1, on Ubuntu 10.10. I have to following .emacs: (custom-set-variables '(cua-mode t nil (cua-base)) '(inhibit-startup-screen t) ) (show-paren-mode 1) (setq show-paren-delay 0) ;; perl mode stuff (fset 'perl-mode…
vkats
  • 117
  • 1
  • 8
0
votes
1 answer

Xemacs perl compilation can't go to error position, by showing "Wrong type argument" error

After compilation of perl script I get syntax error in compilation window. If I try to use Goto Error Command, it not working and show error message: Wrong type argument: listp, "^\\s-*\\(at \\(.*\\):\\([0-9]+\\)\)" I use cperl 6.2 and xemacs…
Gerd
  • 2,265
  • 1
  • 27
  • 46
0
votes
1 answer

How can I configure so that I can define multiple actions in cperl-mode-hook in .emacs?

Here is an excerpt of my .emacs CASE 1: With the config below, perl-completion mode works perfectly. ;;------------------------------------------------------- ;; -*-- CPerl mode ;;------------------------------------------------------- (defalias…
0
votes
1 answer

Emacs: how to get rid of the unwanted tab in perl-mode yasnippet

I have the following yasnippet in perl-mode to create a sub: #name : sub ... { ... } #key: sub # -- sub ${1:function_name} # {{{ { $0 } # }}} But when Emacs expands it, it generates an unwanted tab: sub function_name # {{{ <-- ? { } #…
user4035
  • 22,508
  • 11
  • 59
  • 94
1
2