help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: `align-regexp' fails in Lisp code


From: Jambunathan K
Subject: Re: `align-regexp' fails in Lisp code
Date: Fri, 12 Jul 2013 18:48:47 +0530
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux)

Run the command as usual

    M-x align-regexp RET 

Let Emacs tell you what the lisp representation of it is.  Do

   M-x list-command-history RET

you will find your very recent command there.

Copy, paste that stuff, do some modifications for the region portion and
your are done.

----------------------------------------------------------------

You can also get the lisp representation with

    M-x repeat-complex-command RET

    M-p
    M-p
    
    etc

until you find what you want.



Raffaele Ricciardi <rfflrccrd@gmail.com> writes:

> Hello everyone,
>
> I'm trying to run `align-regexp' from Lisp code, but it fails with
> the error "align-region: Marker does not point anywhere".
>
> Here is the specification of `align-regexp':
>
> ---
>
>     (align-regexp BEG END REGEXP &optional GROUP SPACING REPEAT)
>
> Align the current region using an ad-hoc rule read from the
> minibuffer.  BEG and END mark the limits of the region.
>
> ---
>
> Here is my Lisp code:
>
>     (align-regexp (point-min) (point-max) " hides ")
>
> Marking the whole buffer and calling `align-regexp' interactively does
> work, though.
>
> Tried with "emacs -Q".  I'm using GNU Emacs 24.3.1.
>
> Thank you for your attention.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]