Jump to content

AScript Script Reference


Niemand

Recommended Posts

I'm happy to report that I'm making good progress on completing AScript. It now does simple auto-indentation and is less inclined to lose custom snippet data. Most significantly, I think I've come up with a good way to do the online script call reference, as suggested by Kelandon. I have the engine working, so there's only one thing I lack: content to put in it. I could just copy and paste what Jeff wrote in the Editor manual Appendices, but that has several problems: it would be very laborious, the descriptions even in the newest version are sometimes terse or incomplete, and of course I would have to ask Jeff's permission to use the material. So, I think it would be possible to do better, namely by drawing on the knowledge of the community. The system I have would require an html page, preferably short, for each call, although it would be straightforward and useful to link in pages for groups of related calls and for examples. So, I would like to ask if there's anyone who wants to help me generate this content; I would really appreciate it.

Link to comment
Share on other sites

For the record, that was not at all my suggestion. My suggestion was basically what WKS did in his script editor, except in a window instead of a menu.

 

There already exists an online script reference. I'm not sure what purpose a new one would serve.

 

The whole point of a script editor is to get everything in one application. If we're putting script reference stuff into a second application (a web browser or something), then why not just have Word open and look at the usual docs?

Link to comment
Share on other sites

I would be happy to have your help, WKS. As with all other portions of AScript, I had intended the reference material to be freely available for use anywhere. From a quick bit of research and experimentation JTextPane seems to render HTML tolerably in Java if you're interested in literally using the same set of files for convenience.

 

EDIT: Now that I've finally gotten through the server errors, I can finally see Kelandons's post and my own. I really misunderstood what you meant then, Kel, but I think that what I'm working on would really be far more useful to me when scripting, at least. I personally find the structuring, or lack thereof, of the wiki to render it almost unusable, the formatting is simplistic at best, and it really the same information or less as in the appendices. To make things clear, nothing is in another application. AScript has a window, which happens to be capable of rendering HTML, in which it displays pages which can have anything on them that we want. I want to be able to do is put the text cursor on a call, press a key, and see the definition and details of the call, so that is what I'm building. It would also be usable as a simple list of calls with the main page listing categories and the category pages linking to the individual calls' pages. Inserting a call is already easy with auto-completion, without having to locate it in a menu or a large list. (Depending on how much of the call you type to start with.)

Link to comment
Share on other sites

So, if I'm reading you right, it'll be sort of like the way Eclipse displays the javadoc for a method when you type it in?

 

Nifty.

 

--------------------

I worked as a parking attendant at Logan Airport, I parked jets. They had to let me go though because I kept locking the keys in them. One day I was on an 86 foot stepladder trying to get in the window with a coat hanger.

- Steven Wright

Link to comment
Share on other sites

Quote:
Originally written by Niemand:
I really misunderstood what you meant then, Kel
I kept saying that you were completely misunderstanding me at the time. :p
Quote:
Inserting a call is already easy with auto-completion, without having to locate it in a menu or a large list. (Depending on how much of the call you type to start with.)
That reminds me of two things. First, auto-complete doesn't serve the purpose that I want (e.g. "There are three similarly-named called that do this, and I remember what one of them was, but I want to look at all three so that I can compare"). It sounds like what you're doing now would solve the problem, though.

Second, AScript doesn't auto-complete right now. Is it supposed to?

EDIT: Also, I always intended to rewrite the documentation. This might be my chance.
Link to comment
Share on other sites

Yes, it does auto-complete. Type part of a script call or reserved word and the press Option+Space or Option+Esc. At least it works fine under 10.4, I hope that this isn't something that doesn't work under Panther.

 

As to how I'm planning to rewrite the docs:

I have a list of 494 calls and keywords (The same ones that AScript can auto-complete). My idea is to have a short page for each one, describing it's usage and parameters. There would be ~40 category pages that would link to all the calls/keywords in that category. There would then be a main page which links to all of the categories. In addition, each call's page would have a 'See also' section linking directly to closely related calls, and category and call pages could link to pages containing examples and explanations. So all told as many as 600 pages. However, many would be short and would take about 2 minutes to write; so with several people collaborating, I don't see it as being impossible. So far I have a program which generates the 494 call and keyword pages needing only to have their content filled in, and I've learned some css for doing the formatting of all the pages. Right now, I am working on sorting the calls into categories, mostly following the categories in the Docs Appendices but with some changes.

Link to comment
Share on other sites

Hmph. It's a beta. I am writing the documentation, for release with the complete program. So far it's 7 pages long so far (With lots of screenshots, which are often more work that a block of text of the same size.), and may still need to double in length. It wasn't something I could just create with a snap of my fingers. Besides, if you looked in the menus, you'd see the shortcut listed. :p

Link to comment
Share on other sites

Huh. I didn't notice those extra commands in the edit menu. You have Auto-Complete, Jump To Line, and Check With Alint in the menu, but you have Check With Alint, Count Characters, and Jump To Line as buttons on the top of the window.

 

That's weird. Why not just include all four in both places?

Link to comment
Share on other sites

Count characters is in the menu in the next version; I just forgot it the first time. Auto-complete doesn't make much sense as a button, and I only made it a menu so that there would be some way to see that it exists. A quick test shows that Option+Escape and the menu item don't work at all, oops, and so I'll be either fixing or removing it.

Link to comment
Share on other sites

  • 3 weeks later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...