elisp - Control the order in which customization options appear? -


in major mode, have options defined defcustom , defface. each assigned same :group defined via defgroup.

when m-x customize-mode, options appear , work correctly.

however don't order in appear. example i'd put @ top customizations users more need or want change.

unfortunately can't figure out how emacs determines order. example doesn't seem correspond order in defined in .el file, or alphabetical sort of doc strings or :tags. maybe i'm overlooking obvious, seems be... "random"? in reading elisp docs , searching online haven't found answer.

is possible control order in options appear, , if so, how?

the order of options determined c-h custom.*(sort\|order) ret:

custom-browse-order-groups   user option: if non-nil, order group members within each                customization group.   properties: standard-value custom-type custom-requests               variable-documentation custom-browse-sort-alphabetically   user option: if non-nil, sort customization group alphabetically in                `custom-browse'.   properties: variable-documentation custom-autoload custom-loads               standard-value custom-type custom-requests custom-buffer-order-groups   user option: if non-nil, order group members within each                customization group.   properties: standard-value custom-type custom-requests               variable-documentation custom-buffer-sort-alphabetically   user option: whether sort customization groups alphabetically in                custom buffer.   properties: variable-documentation custom-autoload custom-loads               standard-value custom-type custom-version               custom-requests custom-menu-order-groups   user option: if non-nil, order group members within each                customization group.   properties: standard-value custom-type custom-requests               variable-documentation custom-menu-sort-alphabetically   user option: if non-nil, sort each customization group                alphabetically in menus.   properties: variable-documentation custom-autoload custom-loads               standard-value custom-type custom-requests 

and implemented custom-sort-items.

i.e., can sorted alphabetically , groups can placed first or last.

if want add custom sorting, need modify source or use advice.


Comments

Popular posts from this blog

windows - Single EXE to Install Python Standalone Executable for Easy Distribution -

c# - Access objects in UserControl from MainWindow in WPF -

javascript - How to name a jQuery function to make a browser's back button work? -