help with text code
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 09:18 PM
Michele
1100: !square
PEN gs_cont_pen
RECT2 0,0,a_size,b_size
PEN 91
DEFINE STYLE STYLE_12 "Arial", 35 * MIN (a, b), 7, 2
!!!!!THis is moveable text hotspot and text for more_text
STYLE STYLE_12
PEN cpen
rot2 -symb_rotangle!!This rotate text to follow object
unID = 1
HOTSPOT2 0, dd_y,unID, dd_x,1+128 : unID=unID+1!!!THis is moveable hotspot placement
HOTSPOT2 -1, dd_y,unID, dd_x,3 : unID=unID+1
HOTSPOT2 dd_x,dd_y,unID, dd_x,2 : unID=unID+1
HOTSPOT2 dd_x, 0,unID, dd_y,1+128 : unID=unID+1
HOTSPOT2 dd_x, -1,unID, dd_y,3 : unID=unID+1
HOTSPOT2 dd_x,dd_y,unID, dd_y,2 : unID=unID+1
ADD2 dd_x, dd_y
TEXT2 0", 0",(descrip_equip)!!the 0",0" is text hotspot placement
DEL 2
PEN pen_clear
SET LINE_TYPE "TRI Demolition"
SET FILL "Air Space" !1' is a_size 2' is b_size
POLY2_B{2} 5, 3, 0, 0,
0'-0.0000", 0'-0.0000", 0'-0.0000",
0'-0.0000"-left, 0'-0.0000"-bottom_, 1,
a_size + right, 0'-0.0000"-bottom_, 1,
a_size+right, b_size+top_, 1,
0'-0.0000"-left, b_size+top_, 1,
0'-0.0000"-left, 0'-0.0000"-bottom_, 1
RETURN

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 09:26 PM
Also, is subroutine 1100 being called from somewhere? Otherwise the code you have here will not run at all.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 09:45 PM
I even get the green hotspot for the text like I do in my other object but no text. I zoomed extents in an empty file and still no text displayed.
So the code looks fine as long as I'm adding parameters and I'm calling the sub routine?
Any other ideas??!!

Michele

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 09:47 PM
Also, try replacing the variable with a literal, like "My Text" (with quotes) to see if it's the variable or if it's the text settings.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 09:53 PM
Thanks again,
Michele
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 10:02 PM
Thanks for helping,
Michele
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 10:10 PM
I want the text to be underneath the object. I kind of want the text to show up only for my benefit and not be printed. I have it on the 91 color but it looks like it will cover up my object in parts!
Thanks,
Michele

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 10:32 PM
Michele wrote:Oops, sorry!
If you look in the code I added to the original post it does define the style. And I tried changing the variable to "my text" with no luck
Thanks again,
Michele

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 10:33 PM
Michele wrote:Technically there is no such thing as "non-printing" in Archicad. There is only "prints white so you cannot see it", but sometimes that covers other things
Another question,
I want the text to be underneath the object. I kind of want the text to show up only for my benefit and not be printed. I have it on the 91 color but it looks like it will cover up my object in parts!
Thanks,
Michele
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
2006-07-20 10:45 PM
Thanks again,
Michele
Here's all the code in 2D
HOTSPOT2 0,0
HOTSPOT2 a_size,0
HOTSPOT2 a_size/2,0 !down
HOTSPOT2 a_size,b_size
HOTSPOT2 0,b_size
!hotspot @ clearances
HOTSPOT2 0'-0.0000"-left, 0'-0.0000"-bottom_
HOTSPOT2 a_size + right, 0'-0.0000"-bottom_
HOTSPOT2 a_size+right, b_size+top_
HOTSPOT2 0'-0.0000"-left, b_size+top_
HOTSPOT2 0'-0.0000"-left, 0'-0.0000"-bottom_
PEN gs_cont_pen
RECT2 0,0,a_size,b_size
PEN 91
DEFINE STYLE STYLE_12 "Arial", text_size, 7, 6
!!!!!THis is moveable text hotspot and text for descrip_equip
STYLE STYLE_12
PEN 91
rot2 -symb_rotangle!!This rotate text to follow object
unID = 1
HOTSPOT2 0, dd_y,unID, dd_x,1+128 : unID=unID+1!!!THis is moveable hotspot placement
HOTSPOT2 -1, dd_y,unID, dd_x,3 : unID=unID+1
HOTSPOT2 dd_x,dd_y,unID, dd_x,2 : unID=unID+1
HOTSPOT2 dd_x, 0,unID, dd_y,1+128 : unID=unID+1
HOTSPOT2 dd_x, -1,unID, dd_y,3 : unID=unID+1
HOTSPOT2 dd_x,dd_y,unID, dd_y,2 : unID=unID+1
ADD2 dd_x, dd_y
TEXT2 3", 3",(descrip_equip)!!the 0",0" is text hotspot placement
DEL 2
PEN pen_clear
SET LINE_TYPE "TRI Demolition"
SET FILL "Air Space" !1' is a_size 2' is b_size
POLY2_B{2} 5, 3, 0, 0,
0'-0.0000", 0'-0.0000", 0'-0.0000",
0'-0.0000"-left, 0'-0.0000"-bottom_, 1,
a_size + right, 0'-0.0000"-bottom_, 1,
a_size+right, b_size+top_, 1,
0'-0.0000"-left, b_size+top_, 1,
0'-0.0000"-left, 0'-0.0000"-bottom_, 1