[Top][All Lists]

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

Re: What standard library to use to provide settings editing to user?

From: Oleksandr Gavenko
Subject: Re: What standard library to use to provide settings editing to user?
Date: Thu, 28 Feb 2013 20:52:48 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux)

On 2013-02-20, Oleksandr Gavenko wrote:

> I write blogging mode and want to provide ability to users to list and edit
> connection settings.
> As I use external program to do actual authentication and network jobs so I
> don't use Emacs variables for storing settings.
> External process send list of parameters and their values. I should show them
> to user and return user modifications back to external process.
> Every parameter have a name and string value (possibly multi-line).
> What libraries or code examples are usable for solving such task?

Firstly I try use low level API:

  (info "(elisp) Text Properties")

but stuck with:

  (info "(elisp) Sticky Properties")

when I need to code boundary between editable and read-only areas...

After looking how is work "M-x customize-mode" I found:

  (info "(widget)")

Some practice and I get working code. Most useful feature is 'widget-value'

But some parts are very hard to understand. For example how can I make custom
face in widget-insert? I use such code, it work but I don't know if this right

    (put-text-property 0 (length blog4y*conf-header-id) 'face 'bold 
    (widget-insert blog4y*conf-header-id id "\n\n")

Best regards!

reply via email to

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