I refactored all requires to point at `ace/ext/modelist` deleted the
build directory and did a full rebuild. In both the kitchen sink and the
mode creator I was able to use the mode lists and see an immediate
reaction in the applications. I think it worked out. :D
I copied the modelist.js file from the kitchen sink demo and added doc
comments to the exported methods.
This module would be extremely helpful to anyone implementing a menu
system or who wanted to programatically switch rendering modes based on
the file extension of the file loaded into ace. I can think of several
use cases for it already. (1) in the settingsMenu branch. (2) in
supporting theme switching for anyone implementing drag and drop support
for loading files into the editor (3) in supporting theme switching for
sites implementing their own file picker dialogues and loading content
into ace through xmlhttprequest (4) in supporting filebrowser / editor
applications where a server could be set up to display file contents in
an ace editor as users browsed to arbitrary files. (5) etc. etc.
Had I known about it when I began writing the settingsMenu branch I
would have used it.
This branch now depends on the modelist being pulled in as a module. I'm
using the modelist to generate the menu options for switching modes
because it's redundant to have the same massive list in two places.
The modelist module also has some awesome features so I choose it over
my silly list. :D
When the editor takes up the entire window and the window is only half
the size of my screen, the menus get crunched up horribly. I'll provide
for closing the overlay by pressing esc in case the overlay's contents
take up the entire screen.
If ace is to be used in very small frames then implementors will need to
provide styling information in css to control how the settings menu
looks.
The overlay menu should remain visible when scrolling a long page. The
intention is to present information on demand and not leave the menu on
screen. If allowed to scroll away the remaining element could interfere
with the page.