Home Download Buy Blog Forum Support

An idea for building a visual interface for settings, etc

An idea for building a visual interface for settings, etc

Postby tito on Wed Nov 09, 2011 11:01 pm

Hi,
I feel sometimes using this editor I need some way to tweak/modify/remove/see/etc, preferences via a visual interface. Find a keymap, toggling something, etc

I think is great these settings are mainly json files because these provide flexibility. While at the same time, keep main developer with focus on important things such core behaviour, and low level APIs for developers. ; )

The idea is.. instead of build a complicated python interface with little or limited options ( dialogs, forms, etc ) why not build a HTML/JavaScript interface using the new HTML5 File system API
http://www.html5rocks.com/en/tutorials/ ... ir-reading

Anyone with a chrome browser or Mozilla browser will probably be able to scan the package directory and make changes via a cross platform interface, probably in a single HTML file.

I would like to think most of us, know little bits of JavaScript.. is likely to not be so difficult to write or recycle some code, with bumped options, some of my imagination:
- quickly find any setting/keymap etc
- a boolean toggling
- a colour picker
- key bindings detection and modification, alert of already used keys

There is room for imagination, a lot of room,
don't know just an idea.

Here comes the summer, is likely that I will not be able to work on this.
If some day I found the time and motivation needed, may I start something.

Regards
Give APIs, let the community build the rest!
https://github.com/titoBouzout
tito
 
Posts: 851
Joined: Thu Sep 29, 2011 2:27 pm
Location: Montevideo, Uruguay

Re: An idea for building a visual interface for settings, etc

Postby spadgos on Thu Nov 10, 2011 8:34 am

It does sound like a nice idea, however one issue is that the range of valid options are not specified anywhere. For example, an interface needs to know which values to offer to the user - a checkbox, radio buttons, an array of textboxes, etc.
spadgos
 
Posts: 121
Joined: Thu Oct 06, 2011 12:49 am

Re: An idea for building a visual interface for settings, etc

Postby facelessuser on Thu Nov 10, 2011 3:51 pm

I think I agree with spadgos on this one. Though the initial idea sounds nice, I am not sure how practical it is. If you were able to force a standard convention for naming settings (setting1_bool, setting2_list), you would have an easier time. Also, I am not sure I want to open a web browser window to change things in the editor.

It is true we are in age of the GUI, but to be honest, the settings are simple text strings that could easily be managed through sublime. You could pole all the settings and pop them up in a quick panel allowing for searching by typing. If one is selected, simply pop up an input panel with the name of the setting and the value in the editable box. I think this would be a very usable system, and probably not to hard to code up. I think it is one of those things were simplicity is best...but I realize this is also a personal preference thing.

Edit: Thinking about this more, I think I am oversimplifying the issue. You would have to allow the adding additional settings files to pole that are not in the base file settings. You would also have to save the settings to "User" variants of the settings file (creating it if it does not exist). It does actually sound like a lot of work with or without a gui. I don't know, I guess its a toss up, it might be one of those things, if someone came up with a really good implementation, everyone would use it. I don't mind the json settings though, what might be nice is a quick panel plugin for showing all the settings files and allowing you to open the one you select; you could even show a transient view of the selection that is highlighted. I think this would be easier and obtainable.
facelessuser
 
Posts: 1544
Joined: Tue Apr 05, 2011 7:38 pm

Re: An idea for building a visual interface for settings, etc

Postby tito on Thu Nov 10, 2011 11:01 pm

It should be very dynamic, yeah.
Detection of boolean and colours should be easy, also some value "keys" are easy parseable. Its possible.
Give APIs, let the community build the rest!
https://github.com/titoBouzout
tito
 
Posts: 851
Joined: Thu Sep 29, 2011 2:27 pm
Location: Montevideo, Uruguay

Re: An idea for building a visual interface for settings, etc

Postby facelessuser on Thu Nov 10, 2011 11:31 pm

True, a lot of things can easily be identified, but how do you identify something like this:

Code: Select all
"example_setting" : [],


It could be an array of anything: string, number, an array of arrays. Without some kind of convention set forth, you would be no better off than javascript is in these situations; all you know is it is an array...of something.
facelessuser
 
Posts: 1544
Joined: Tue Apr 05, 2011 7:38 pm

Re: An idea for building a visual interface for settings, etc

Postby facelessuser on Thu Nov 10, 2011 11:31 pm

Double post.
Last edited by facelessuser on Thu Nov 10, 2011 11:32 pm, edited 1 time in total.
facelessuser
 
Posts: 1544
Joined: Tue Apr 05, 2011 7:38 pm

Re: An idea for building a visual interface for settings, etc

Postby tito on Fri Nov 11, 2011 12:06 am

The thing should be recursive. You will always end with a string, int or number or any other conventional type.
Give APIs, let the community build the rest!
https://github.com/titoBouzout
tito
 
Posts: 851
Joined: Thu Sep 29, 2011 2:27 pm
Location: Montevideo, Uruguay

Re: An idea for building a visual interface for settings, etc

Postby facelessuser on Fri Nov 11, 2011 12:25 am

Yes it should be recursive, but not all setting will end with a string. For instance, I think sublime linter provides empty arrays for defining lint parameter overrides, but they can be left empty if you wish to accept the defaults.

I guess you could pick an assumed default for empty arrays if you allow it to be changed. By no means do I think the project is impossible, I just wonder how practical it would be. Most settings dialogs work because they are planed out and designed. I worry that a dynamic dialog would be not much better than looking at a json structure, albeit a bit more pleasing in style.

It would seem if you wanted to make intuitive dialogs in a web app or whatever, you would need to require the json setting file, and maybe a dialog mapping config. That way you could render a dialog with tabs that sort related settings, the renderer would be aware of how to render the settings, provide explanations/help info for settings, etc.

I think organization of settings is the real benefit of using dialogs, if this was done, it would be worth using.
facelessuser
 
Posts: 1544
Joined: Tue Apr 05, 2011 7:38 pm

Re: An idea for building a visual interface for settings, etc

Postby facelessuser on Fri Nov 11, 2011 12:55 am

Running with the dialog config mapping, this would also allow for the specifying of how to present data to the user.

If you had only certain valid ints: present a drop down menu

If you have a range of values: present a slider

If you have an unknown range, just give a text box

These things can only really be determined if there was some kind of config.
facelessuser
 
Posts: 1544
Joined: Tue Apr 05, 2011 7:38 pm

Re: An idea for building a visual interface for settings, etc

Postby elis on Sat Nov 12, 2011 3:22 pm

I support this idea, and could help with a few aspects of it (GUI, design, code).

Regarding settings and what values should be attached to what setting - it could be easily fxed by creating a mapping file that will tell the configuration app what each thing is and how to display/interact with it. Plugins could have a small JSON file attached to them that would serve the same purpose. At the very first days of this settings GUI we could manually do the mapping and it will accumulate as we go on, nothing too complicated.

GUI can be initially be based on a free theme, while writing this reply I've started this: http://dl.dropbox.com/u/1290056/sublime ... index.html .

If this moves anywhere, I'd be happy to be kept in the loop, my email is eli.sklar@gmail.com
elis
 
Posts: 2
Joined: Sat Nov 12, 2011 2:48 pm

Next

Return to Ideas and Feature Requests

Who is online

Users browsing this forum: No registered users and 4 guests