[Plugin] Title block from title v1.2 (20110713)
-
**%(#408040)[EDIT : New version 1.2 (20110713) :
- Hlp file added
- %DIR variable added. Puts directory of the drawing in cartouche)
- %PAGE variable added. Puts name of the current scene in the cartouche. And every change of page will also modify cartouche.
- %N variable added. Puts N° of the scene.
- Modify call of case change.
- Now you must show where the information is in the title. So now you can change order of title information.
- / symbol added. Put it at the end of a field value in settings, and script will not put information on a new line.
EDIT : New version (1.101): small bug.]**
This post is just a copy of Help file in the package. Sorry for my poor english...
1. Overview
Matt_Cartouche is a script that inserts a title block (in fact a simple screen text) which is composed of elements included in the drawing title and some variables.
2. Installation
Just unzip Matt_Cartouche.zip in the plugins folder.
This file is composed of : [floatr:2tdluwvt][/floatr:2tdluwvt]
-
The main script (“Matt_Cartouche.rb”)
-
A folder called “Matt_Cartouche” :
-
Images for the toolbar
-
Some translation files
-
Settings file (“settings.txt”)
[floatr:2tdluwvt][/floatr:2tdluwvt]
After installation, run SU. Matt_Cartouche will create a sub menu in “plugins” menu and a toolbar composed of two icons.3. To use Matt_Cartouche
Before using this script you must configure your drawing title and cartouche settings.a) Drawing title
To find informations in the title, Cartouche will need a separator. You can use separator you want, but it must be written in settings. For example:ARMSTRONG#New Orleans#Trumpet#ind_A.rb
You can see a separator in the title (“#”), and 4 informations: “ARMSTRONG”, “New Orleans”, “Trumpet” and “ind_A.rb”. For now Cartouche doesn’t know what this informations correspond to, you will help it in settings.
b) Cartouche settings presentation
You can open it by clicking on the second icon or going to menu plugins/Cartouche/Settings. Settings is a dialog box with some fields.
You can see Cartouche can have 8 fields. Fields can be composed of simple texts, variables, and title parts. Let me explain you how it works.c) Title order vs Cartouche order
You have to distinguish title informations order, and cartouches fields order. That’s very important. In my example ARMSTRONG is the first title information, but you can put it at the end of the cartouche! Numbers after @ symbol in the fields value are localisation of title informations.d) Cartouche settings explanations
The most important thing to understand with cartouche is field value parameters. The rest is very simple.
As you can see in the cartouche settings example, there are some symbols in field value.- @ -> Means “the field value is in the title”.
- 1 -> Means “The filed value is title information N°1”.
-
-> Means “This information will appear capitalized in the cartouche”.
- < -> Means “This information will appear with same case in the cartouche”.
- (-1) -> Means “Just write last character in the cartouche”.
- %DATE -> This a variable, it will put current date in the cartouche.
- %DIR -> This is a variable, it will put directory of the drawing in the cartouche.
- %PAGE -> This is a variable, it will put current page in the cartouche. Each change of page will also change this value.
Field 1 value “@1>” means “The field 1 value is title information N°1 and will be capitalized”.
Field 3 value “@3<” means “The field 3 value is title information N°3 and will be written as you write in the title”.
Field 4 value “%DATE” means “The field 4 will be the current date”.
Field 5 value “@5>(-1)” means “The field 5 value is title information N°5, will be capitalized and just last character will be in the cartouche”.
Field 6 value “MN” means “The filed 6 will be “MN””.You can't modify variable case. So you can't use >, <, = or (-1), (1..1), etc.
For information to take from the title, You MUST follow this order:
@ : If you don’t put it, Cartouche will understand what is written is just some text
Integer : To tell to cartouche where information is placed in the title
<>= : To change case of the information
(…) : Optional symbol, for isolating a part of the information
/ : Optional symbol, for staying on current cartouche linee) Tooltip mode
This is an option in cartouche settings. %PAGE variable puts scene tab name in the cartouche. If you validate this option, %PAGE variable will be changed. So if you have an iso view in your scene, name of the iso view will replace scene tab name.f) Cartouche separator
These 2 lines in settings are used with / symbol. When this symbol is at the end of a line in settings, Cartouche understands that information will not be a new text line. So it takes 1st separator to start and 2nd separator at the end.g) Last tool: Record existing cartouche
This tool is used in case of Cartouche creates another text above existing. For example if you delete an existing cartouche, and undo your action, Cartouche will loose text link.h) Examples
With Armstrong example, here is the setting for putting a cartouche:
And with the settings example below, here is the result:
That's all! Do not hesitate to tell me if something goes wrong.
-
Hi, Matt666:
This looks to be very handy.
By way of clarification, does the value in the "X on screen" represent a proportion of the viewing area, or what? If you increase the value, does it enlarge the text?
And, I assume the @ sign is just a variable for the example, otherwise it would say FIELD1? -
Hi mitcorb, and thank you for your answer.
X or Y on screen determinates position of the cartouche in the drawing. Cartouche will move if you change the values. It doesn't change font size.
@ sign means 'value is in the title'. In example above, @ sign is written in value of field 1, and "affaire" (site in english) is written in name of field 1. So plugin will put "Affaire : "+ title field 1 (Affaire : TEST1) on the first line.
Field 1 is the first field in the title. Not in Cartouche. But I can modify script if you want. Field 1 can be the first field in the cartouche. Why not? -
Hi, Matt:
I am not asking you to change anything. I am not so well trained in use of databases, and I am simply trying to understand the usage, or "grammar". -
Ok ,I understand. I have modified plugin, see first post. V1.1
-
So, then, whatever one has named the file is then placed in the database, but you must use # as part of the title, and in the order of the fields. The @ sign tells the cartouche generator to look at the title for the appropriate value?
-
Absolutely.
'#' sign is just the separator of all informations in the drawing title. If you want to use another sign, change title AND whange separator in the cartouche settings.
@ = just look at the title. Just one thing: You can't put ONLY 3rd title information in the cartouche. First and second title information must be in the cartouche. I will try to improve this plugin soon.Just a little improvment : If you put '@@' sign in the value field, information will be capitalized. Otherwise, it keeps title case.
-
Great idea Matt. Thank you for sharing!
-
Thank you Adam!
-
Interesting...thank you. Maybe this plugin will put the order in my su files
-
Hi srx, hope this little script will help you...
-
A small bug-fix.
-
New version soon available (tomorrow). 2 new variables : %DIR (to add directory of the drawing in cartouche) and %PAGE (an interesting variable that add name of the current scene in the cartouche. And every change of page will also modify cartouche).
A help file is here now. I modified call system of case change (no @@, but < or >). And now you can change order of title information.
-
Matt, would it be possible to tie this into the Scene Tabs to change page numbers and label each view according to the named scene tabs? (i.e. Front Elevation, Rear Perspective, etc.)
-
sorry, but I cannot find the link to download this plugin!
-
That's normal, Edson. I work on some improvments, and I will upload it soon.
-
thanks, matt, I thought I had a problem.
-
thanx for ur nice plugins
but Download from Where???
-
Unclex, Matt indicated he was working on improvements. He must have removed the link temporarily.
-
Ok, you can download plugin at the end of the first post.
Enjoy!
Advertisement