Screem | ||
---|---|---|
<<< Previous | Next >>> |
The following are the intended coding style guidelines for screem, I probably haven't stuck to them everywhere though.
Indentation & Formating:
tabs should be 8 characters.
spaces should follow brackets: eg
this_is_a_function( parameter, paramter );
i = array_element[ 3 ];
spaces should follow arithmetic symbols: eg
i ++;
i += 3;
spaces should follow commas: eg
this_is_a_function( parameter, parameter, parameter, parameter );
words in variable and function names are separated with an underscore: eg
this_is_a_very_long_variable_name
New types, eg structs and enums should begin with a capital letter: eg struct Type my_struct;
words in type names are separated by starting the new words with a capital letter: eg: struct MyType my_struct;
As such I have decided that the tag tree will be stored using xml. This will make it very simple to construct the tree as the xml parser can build it, then its just a simple matter of making a GtkCTreeNode for each node in the xml tree.
This will also allow a child depth of more than 1. The widget used will be changed from a GtkTree widget to a GtkCTree widget as well. this will also allow for nodes to have an icon to go with them.
As part of this the plan is as follows: the tag tree will consist of:
[image]
Screem will be distributed with the HTML node and its children as standard. The user can add any other nodes they want, such as javascript, php etc.
Screem utilises shared libraries as a plugin system.
If you wish to create a plugin then take a look at the colourWizard, as it is possibly the simplest code.
The following features that were mentioned in the spec for 0.1 were not implemented:
Syntax highlighting for languages such as perl/java/php etc.
The ability to "publish" a site was not present in the initial 0.1 release although has subsequently been added in 0.1.1 (using FTP and Webdav)
The ability to print the rendered html was not present, and the printing of the source was efectivly useless and only present if gnome-print was installed on the system.
Proper HTML validation wasn't really performed, although warnings were given when elements were entered which were not valid HTML 4.0
The missing features from the 0.1 specification should be included in 0.2.x
The "tag tree" is to be extended to allow a greater depth to the tree, rather than the depth of 1 which is currently allowed. Along with this the storage of the tree is too be moved from $HOME/.gnome/screem to an xml file. The system is to store a global xml file which will be used by all users of Screem on the system. Users can then add more branches to the tag tree by adding separate tree files under $HOME/.screem/*.tagtree.
In a similar fashion to the use of $HOME/.screem above plugins are to be read in the same way. The global plugins are to be loaded first, then the users $HOME/.screem directory is to be scanned for plugins and any that are found are should be loaded.
Templates should be extended to be able to use entire site templates, which contain definitions of a site: ie the directory structure of a site. Upon creating a new site with a template the directory structure would be created in the sites local path. Site templates should be stored in xml files. They should be capable of containing templates for individual pages within themselves, and also for accessing templates from normal files.
A graphical editor should be provided for creating site templates.
There needs to be a method by which the user can select individual or groups of "helper" applications to filter pages through, rather than just executing them all in order as is currently performed.
The ability to map the site directory to a url so that pages can be previewed which need preprocessing or cgi's executing can be viewed correctly.
Auto tag completion should be an option in the editor so that when a < is entered then a corrosponding > will be inserted directly after it and the cursor placed between them. Also when the tag name has been entered the closing tag can be automatically added if required. This feature should be disabled when entering text in a <SCRIPT></SCRIPT> block as it would interfere with entering the scripting language.
The ability to compile java files should be available, with a user defined java compiler.
Submenus should be provided in the editor menu for other languges, mainly PHP, Perl, and Java.
Along with the tag attribute menu a dialog should be made available from which any of the tags attributes can be changed at the same time.
(This is only a draft specification for 0.2.x and as such is likely to be added to or altered, 0.2 will not have a complete feature set, which will be built up as releases progress through 0.2.x)
<<< Previous | Home | Next >>> |
Buttons | Authors |