Re: Re: Screenplay formatter?

fjmancho <[email protected]>
Newsgroups gmane.comp.handhelds.palm.peditors
Message-ID <1790-SnapperMsg89F91E37C57E44D2@[172.27.125.79]>
 ..... Original Message .......
On Sun, 28 Dec 2008 22:01:57 -0000 "daleblizz" <daleblizz-/[email protected]> wrote:




>You've already 
>answered some of the questions I had.  

I see you are getting excited with Teikei; I can tell how much more you'll get with pEdit or/and pTools.



>
>Unfortunately I haven't been able to figure out how to write a pScript yet.  

I think that without pScripts Teikei is a good help for you. I hope you have solved the arrow problem and you can navigate.

The pScripts I was talking about are *onlly* meant to modified the sublist memos I guess you will use. According to my examples: context, ACTORS, and so.

The overall idea is to mark the new words or sentences you want to add to those sublists and to paste them in the respective memos. This could be pScripted so that you don't need to update them manually. Of course, you don't need that but it might be useful.

It is not really an interaction pScript-Teikei. It is about handling and modifying memos. For that reason you don't need pTools BUT the attached  pScripts are suppossed to be run in pTool context (as I explained before I don't own pEdit and I cannot experiment with it). 
If you don't have pTools and are not willing to purchase it you will have to modify some lines in the pScript. They are specific pTool actions which can be perfectly done by pEdit in similar way.
If you own pTools you don't need to modify anything as pTools and pEdit are fully compatible.

If you want to give a try to any of the following pScripts, it would be wise to backup your palm before you do. It is not sure how a particular model of palm responds to pScripting.


I send two main pScripts they take different aproaches. The first one is meant to be run at the end of a work sesion and take the different new actors, locations, etc to different variables so that they can be pasted in the respective memos. I don't know whether this is really practical for you. I guess you would like the new entries available for the ongoing work sesion. That is why there is a second pScript. The second pScript then sends each of the new actors, locations, etc to the respective memos as soon as you run the pScript.


It is important that you follow John M's notes in order to get these pScripts to work.



1. First pScript

{BList::
 /GZ
 /eh /K – /KP
/Ki /K2cA/K2cB/K2cC/K2cD
/&script$[@@BList1@@]}
{BList1::
/&specAct[8]
 /xEpst F3 /p10  /i@@(@A–|[ABCD]+¦.+¬)@@ 
/xEpst fd
/&script$[@@BList2@@]}
{BList2::
/e@/&varSet@[$0,$$]
/&ifScript@ [$0==150,@@BLis5@@]
/&varSubStr@[$I,$&,2]
/&varSet[$1,$I]
/&varAdd[$1,-1]
/&varSubStr[$J,$I,0,$1]
/&script$[@@BList4@@]}
{BList4::
/K4cJ /KP
/&ifGoTo@[$0==66,@@B@@]
/&ifGoTo@[$0==67,@@C@@]
/&ifGoTo@[$0==68,@@D@@]
/Ki /K@ /K4aJ /xn /K. /K2aA
/&ifGoTo@[$0==65,@@Z@@]
/:B
/Ki /K@ /K4aJ /xn /K. /K2aB
/&ifGoTo@[$0==66,@@Z@@]
/:C
/Ki /K@ /K4aJ /xn /K. /K2aC
/&ifGoTo@[$0==67,@@Z@@]
/:D
/Ki /K@ /K4aJ /xn /K. /K2aD
/:Z
/&script$[@@BList1@@]}
{BLis5::/p8/xz}

This pScript looks for all the new marked entries one by one and add them to a four different variables depending of the sort of information the search tool has found.

It works as follows:
The pSearchTool looks for the marks and the text between them. They will be left highlighted. Then the pScript checks whether the highlighted text is A,B,C or D type. Then it gets the useful part of the new text (without marks), replaces the marked text in the memo and adds the text to one of the variables (A,B,C,D) depending of the mark.

Note:

The beginning of the pScript marks the beginning of the memo so that the pScript knows when to stop.

"{BList1::/&specAct[8]...}" has a pTool command which calls a searching tool. If you don't have pTools you will have to adapt this part of the pScript to pEdit.

John could help on that. 

You will need to paste those variables in the sublist. You'll have to open manually those memos and paste.

I would use these pScripts for that:


{PasteA::/K4cA /KP}
{PasteB::/K4cB /KP}
{PasteC::/K4cC /KP}
{PasteD::/K4cD /KP}

John explains in the email bellow (or above) the way of running pScripts. Kindly follow his tips.


2. Second pScript

*This pScript is incomplete*. The last part needs to be tested in pEdit and 
I cannot do it.

The pScript does the following:

It looks for one marked new entry and sends it to the requiered sublist.

(The idea is that you are most likely wanting to add your new entries as you write them so that they are available for your work)

I believe the part of sending the information is perfectly doable in pEdit. At least I have seen in the manual the tool "Go to Memo". 

*This is what still needs* to be implemented: going to the specific sublist memo, pasting at the end of the sublist and coming back to the main memo.


This pScript gets two variables:
$J contains the new entry which has to be pasted at the end of  a specific sublist.

$A contains the "title" of the memo cointaining the specific sublist where we want $J pasted. (I have followed the examples I gave to you in the last post. They have to be adapted to the real "titles").

The pScript keeps the Title of the main memo so that we can come back to it once the new word (or sentence) is pasted.



{s2t0::
 /GZ
/&specAct[10]J1S4d.
/&script$[@@s2t1@@]}
{s2t1::
/&specAct[8]
 /xEpst F3 /p10  /i@@[ABCD]+¦.+¬@@ 
/xEpst fd
/&script$[@@s2t2@@]}
{s2t2::
/e@/&varSet@[$0,$$]
/&varSubStr@[$I,$&,2]
/&varSet[$1,$I]
/&varAdd[$1,-1]
/&varSubStr[$J,$I,0,$1]
/&script$[@@s2t4@@]}
{s2t4::
/K4cJ /KP
/&ifGoTo@[$0==66,@@B@@]
/&ifGoTo@[$0==67,@@C@@]
/&ifGoTo@[$0==68,@@D@@]
/Ki /K@ ACTORS/K.  /K2cA
/&ifGoTo@[$0==65,@@Z@@]
/:B
/Ki /K@ LIGHT/K.  /K2cA
/&ifGoTo@[$0==66,@@Z@@]
/:C
/Ki /K@ context /K.  /K2cA
/&ifGoTo@[$0==67,@@Z@@]
/:D
/Ki /K@ LOCATION /K.  /K2cA
/:Z
/xz
/&script$[@@s2t3@@]}


*NOTE*
There are two commands in this pScript that have to be adpated to pEdit in case you don't own pTools:
/&specAct[8]
/&specAct[10]

If you own pTools, note that  /&specAct[10] has to be configure in continous mode. 


*LASTLY*
pSearchTool has to be pre-configured in this way:

• Open it
• write "3" in the textfield
• Check "use REGEXP", and "within words" boxes
• Press "AddFav" button

The pScripts call this favorite configuration.





I believe once tested the whole operation is fast enough.

Regards,

Jose


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

Latest pedit/pToolSet/LapTopHack at http://www.osuweb.net/~pc/pca/pc_all.zip
pedit/pToolSet/LapTopHack scripting info/resources at http://www.peditors.com
Peditors Forum http://groups.yahoo.com/group/peditors
Unsubscribe by writing to peditors-unsubscribe-hHKSG33Tihh4sT85+ipIM4ckdKdSAMto@public.gmane.org! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/peditors/

<*> Your email settings:
    Individual Email | Traditional

<*> To change settings online go to:
    http://groups.yahoo.com/group/peditors/join
    (Yahoo! ID required)

<*> To change settings via email:
    mailto:[email protected] 
    mailto:[email protected]

<*> To unsubscribe from this group, send an email to:
    [email protected]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.