Re: [Screem-devel] Auto entity insertion
Status: Inactive
Brought to you by:
davek
From: David A K. <da...@ri...> - 2000-05-29 17:05:27
|
Lee Mallabone <le...@ca...> writes: > detect if the cursor is between <? and ?> as well as <script> and </script>, > that would also be great. I'm not a fan of <? and ?> really as it doesn't validate on the w3 web site validator thing :-) > I think one of the big uses of scripting stuff is to do conditional things, and > trying to use a simple && operator is not very nice when screem wants to > substitute it for multiple & entities. It is a bit annoying, I'm playing about with PHP myself. > The reason is simple - try and type the following into screem: > > <FONT FACE="Arial, Helvetica"> > > Maybe I'm missing something, but I'm unable to actually insert the space You are missing something, just keep typing and your text will be entered, or press space again and a space will be inserted, although this depends on the mouse not being over a menu item. > character without the popup menu appearing. Pressing escape doesn't actually > insert the space I typed, it just dismisses the menu. Which can get really > irritating really quickly. I'll sort out the escape key thing. It may also be an idea to check if the cursor is in an entity. > It might be nice to have a modifier key, (CTRL, for example), so that if its > held down, entity insertion/completion will definately be done. > That way, if I wanted a bit of HTML in my perl script, I could get on with > coding perl hassle-free, and hold down CTRL for a few entities... thats a good idea, as you say html may be wanted in a script. > > At the moment I'm inclined to disable entity insertion if the cursor is > > within a script context. The plan is to take the same course of > > action with respect to auto closing tags as well. > > Is "a script context" currently just between <script> tags? I'm sure there well thats what I initially meant. > quite a few more contexts that should probably looked into and implemented, if > that's the case. SSI & PHP are all easily embedded into html without any > <script> tags, for example. So the cases that need to be handled are: <script> <? ?> <% %> <!-- --> any others? > > On a relation note, should a menu item be added to the popup relevant > > to the scripting language being used in that context? > > I'm not sure the popups are currently useful in a scripting context at all... > But I might be convinced otherwise. :) I've no idea what they could be used for either, but I'm sure there is a use somewhere. David -- Make your site SCREEM - Site Creating & Editing EnvironMent URL: http://www.screem.org/ Mail: da...@sc... |