think I can pull it off??

Thinking of Micheal here mostly, but any opinion welcome.
I have been rewriting some of my lisp that draws windows, most of the
latest revisions were to incorporate default values that updated when I drew something. That was a large improvement over entering data each time, but....
I am feeling ambitious now.
How about writing an ASCII file, saved to the hard drive, and read in as a variable which would be default values on steroids. dotted pairs.....
A list which contains ALL the possible known numbers (like height & width) cast in stone, and a recommended value for things like trim width which varies. Use dotted pairs like maybe ((width . 36)(height . 60)........) keyed to the designator. no, you idiot, not DOTTED pairs. just a generic association list. dots are for pairs that have integer values in the first slot.
So a 30" x 60" casement hinged left might start something like this:
( (desig "C2650") (type "C") (width 30) (height 60) (trim_width 3.5) (hinge "Y" "L") ..............)
use the assoc command to retrieve values and insert into the lisp I already have that actually does the drawing.....
think I can get that typed in this weekend? if I skip church?
get it up and running and I could create a master text file that would be able to do doors, garage doors, cabinets. this is getting more interesting the more I turn it over.
parametrically speaking.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload

Typed is one thing, debugged is another.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
This is a multi-part message in MIME format. --------------020705050005010906090809 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit
Michael Bulatovich wrote:

only too true.
as kindly old Prof Tolkien once offered, "the tale grew with the telling." as I ponder I keep getting more ambitious.
but I am knee deep in my review of association lists right now. car & cdr / cons v.s. list
I have created a bare bones association list and can manage extracting the data. will have to review readfile command. I am juiced.
I am just punching the keys between here and creating the association list that would feed all the data to an existing routine. ..........
coffee. more coffee.
:)
--------------020705050005010906090809 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type"> <title></title> </head> <body bgcolor="#ffffff" text="#000000"> <font face="Arial">Michael Bulatovich wrote:</font>
<pre wrap=""><font face="Arial"> Typed is one thing, debugged is another.
</font></pre> </blockquote> <br> only too true.<br> <br> as kindly old Prof Tolkien once offered, "the tale grew with the telling."<br> as I ponder I keep getting more ambitious.<br> <br> but I am knee deep in my review of association lists right now.<br> car &amp; cdr / cons v.s. list<br> <br> I have created a bare bones association list and can manage extracting the data.<br> will have to review readfile command. I am juiced.<br> <br> I am just punching the keys between here and creating the association list that would feed all the data to an existing routine.<br> ..........<br> <br> coffee.<br> more coffee.<br> <br> :)<br> </body> </html>
--------------020705050005010906090809--
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload

I've never yet tried to write to/read from a file.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
This is a multi-part message in MIME format. --------------070007000407090306040706 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit
Michael Bulatovich wrote:

</font></pre> <blockquote type="cite"> <pre wrap=""><font face="Arial">Michael Bulatovich wrote:
</font></pre> <blockquote type="cite"> <pre wrap=""><font face="Arial">Typed is one thing, debugged is another.
</font></pre> </blockquote> <pre wrap=""><font face="Arial">only too true.
as kindly old Prof Tolkien once offered, "the tale grew with the telling." as I ponder I keep getting more ambitious.
but I am knee deep in my review of association lists right now. car &amp; cdr / cons v.s. list
I have created a bare bones association list and can manage extracting the data. will have to review readfile command. I am juiced. </font></pre> </blockquote> <pre wrap=""><!----><font face="Arial"> I've never yet tried to write to/read from a file.
</font></pre> </blockquote> it's not exactly convenient. but not as hard for me as error trapping, which you seem to have mastered.<br> <br> NOT GOING TO MAKE IT.<br> <br> but I beg pardon, the wife did not let me. she gave me (ugh!) work to do.<br> billable time -&nbsp; elevations at 45&ordm; with half stone and rounded shutters.<br> she did not want to draw that. hmmmm.<br> <br> but I still might have made it since I "appropriated" some code from Kenny.<br> the read-line returns a single line and treats it like a single word.<br> Kenny's code parses for "," and separates the words from a comma deliminating file.<br> but then he uses <font color="#3333ff">atof&nbsp; <font color="#000000">to&nbsp; convert to a real number. which is cool if you want only numbers.<br> but I want an ordered list of ordered lists which would include ASCII - they use letters in designators too.<br> <br> if </font></font><font color="#3333ff">atof </font><font color="#3333ff"><font color="#000000">would just go ahead and FAIL nicely, I would have an easy time of it.<br> but no, it returns zero, which MIGHT be a good response......<br> hate that word "might" when writing a program. I like to be sure. <br> :)<br> <br> think I will swipe his character parser routine, or rather re-engineer it, so that it sets a flag when<br> an non-digit is encountered. if the flag is set, keep it text. if the flag is clear, convert to real number.<br> <br> but my play time was largely denied me, so I am not going to make my "deadline".<br> <br> I have one routine I remember, which I use, that takes some data out of a file, most of which is in my<br> title block, like client name and plot date, sheet size, number of pages, etc, and writes to a text file.<br> then I cut &amp; paste that snippet into the zip when I archive and when I send plot files to be printed.<br> <br> handy.<br> </font></font> </body> </html>
--------------070007000407090306040706--
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload

You've clearly got me confused with some other Michael Bulatovich. I almost never bother with error handlers.
--


MichaelB
www.michaelbulatovich.ca
  Click to see the full signature.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
This is a multi-part message in MIME format. --------------080605080301040304010508 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit
Michael Bulatovich wrote:

I do have memory problems. some stray recollection was that you understood a question well enough to make an intelligent comment. which surpassed me.
I have downloaded and read some of your code for examples when I wanted to do something similar. no, it was not bogged down with error trapping.
write tight code in the first place and she runs. otherwise, not.
by the way, I am from southern Missouri, and I am quite fond of Walnut trees...... :)
partly talking to myself now, I am going to need to parse character by character to test whether the string will remain a string or be converted to a real number. but I think I can still use Kenny's basic routine. I nested the list statement with success to created a list that looks more like the DFX code I meant to imitate.
but WHILE loops long evaded my comprehenssion. and Kenny is good with them, and it is an effort to read through his work. but I am thinking I can add a conditional statement to control the atof function testing for an ASCII range.
in the process I think I learned something. the "\" character is WITHIN THE RANGE you have to include to get digits AND + & - for a number. you WILL need negative numbers, and "\" is in the range. any conversion that tests like I intend would either have to include this symbol or write just as much of a test to re-include it.
this is (maybe) why different programs treat "\" and "/" so differently. which is fun because of it's arcane nature. but it's just an educated guess.
Kenny's routine parses one "word" into any number of "words" based upon commas in the string. cool. but he always converted to reals. my test, I think, needs to be something like (not (< 45 (ascii x) 58))
I think.....
--------------080605080301040304010508 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type"> <title></title> </head> <body bgcolor="#ffffff" text="#000000"> <font face="Arial">Michael Bulatovich wrote:</font>
<pre wrap=""><!----><font face="Arial"> You've clearly got me confused with some other Michael Bulatovich. I almost never bother with error handlers. </font></pre> </blockquote> I do have memory problems. some stray recollection was that you understood a question well enough to make an intelligent comment.<br> which surpassed me.<br> <br> I have downloaded and read some of your code for examples when I wanted to do something similar.<br> no, it was not bogged down with error trapping.<br> <br> write tight code in the first place and she runs. otherwise, not.<br> <br> by the way, I am from southern Missouri, and I am quite fond of Walnut trees......<br> :)<br> <br> partly talking to myself now, I am going to need to parse character by character to test whether the string will remain a string or be converted to a real number.<br> but I think I can still use Kenny's basic routine. I nested the list statement with success to created a list that looks more like the DFX code I meant to imitate.<br> <br> but WHILE loops long evaded my comprehenssion. and Kenny is good with them, and it is an effort to read through his work.<br> but I am thinking I can add a conditional statement to control the <font color="#3333ff">atof </font>function testing for an ASCII range.<br> <br> in the process I think I learned something. the "\" character is WITHIN THE RANGE you have to include to get digits AND + &amp; - for a number.<br> you WILL need negative numbers, and "\" is in the range. any conversion that tests like I intend would either have to include this symbol or write <br> just as much of a test to re-include it.<br> <br> this is (maybe) why different programs treat "\" and "/" so differently.<br> which is fun because of it's arcane nature. but it's just an educated guess.<br> <br> Kenny's routine parses one "word" into any number of "words" based upon commas in the string. cool.<br> but he always converted to reals. my test, I think, needs to be something like<br> (not (&lt; 45 (ascii x) 58))<br> <br> I think.....<br> </body> </html>
--------------080605080301040304010508--
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload

It's true that the more you anticipate errors when you write your code the less error handling is required, but I think I only messed with error handlers once or twice. If you've read my code then you know it's not the most economical, but is usually pretty easy to follow. I don't bother with error handlers because I'm usually the one running the routine, or it's someone sitting next to me. When they do the job, the thrill goes out of it for me. I've only done one or two dialog boxes too. Way too much trouble for most routines, IMHO.
--


MichaelB
www.michaelbulatovich.ca
  Click to see the full signature.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type"> <title></title> </head> <body bgcolor="#ffffff" text="#000000"> <font face="Arial">Michael Bulatovich wrote:</font>
<pre wrap=""><!----><font face="Arial"> It's true that the more you anticipate errors when you write your code the less error handling is required, but I think I only messed with error handlers once or twice. If you've read my code then you know it's not the most economical, but is usually pretty easy to follow. I don't bother with error handlers because I'm usually the one running the routine, or it's someone sitting next to me. When they do the job, the thrill goes out of it for me. I've only done one or two dialog boxes too. Way too much trouble for most routines, IMHO. </font></pre> </blockquote> <br> I had a humble opinion once, but I had to give up <b>something </b>for Lent.<br> think that was in '92.<br> <br> confidence is so much more fun than that other thing.<br> <br> I agree with you about the trouble writing dialog boxes, but I would still like to master it.<br> 4:30 - have it up and running and it handles both text and numbers.<br> <br> had one conditional test for digits, and one for the commas, and there was a glitch running both.<br> took a while to see that.<br> <br> that and I had a glitch when I had just "finished", and I lost my file. pretty much had to start over.<br> faster the second time, like always. and a good thing, I finally figured out and used the WATCH box in Vlisp.<br> real handy for debugging loops.<br> <br> I would like to tighten it up just a little. the way he kept a counter for absolute placement in the string,<br> and the counter for the number of characters BETWEEN commas, <br> left me running the piece that appends to the file twice.<br> once at every comma, and once at the end.<br> <font color="#cc0000"></font><br> <br> which makes sense, but I can cut out 10% of the code for redundancy if I use an OR in my test.<br> &nbsp;&nbsp;&nbsp;&nbsp; I think..........<br> <br> <br> and besides, right now it reads<font color="#cc0000"> (setq x (substr data (+ 1 (- count chrct)) (- chrct 1)))<br> <font color="#000000">and it bugs me to add one just so I can subtract one. I think it will work if I just set<br> chrct to 0 instead of to 1 in the first place. should look more like<br> </font></font><font color="#cc0000">(setq x (substr data (- count chrct) </font><font color="#cc0000">chrct </font><font color="#cc0000">)) <br> <br> </font>cheers.<br> <br> this is fun.<br> </body> </html>
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
would you be money ahead to just make blocks of the windows? how many different types / sizes are there?
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload

I use a simple routine that draws windows in elevation to any size that I want with some control over the elements in them. In some work, window sizes are all custom, so blocks are to static and limiting.
--


MichaelB
www.michaelbulatovich.ca
  Click to see the full signature.
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload
This is a multi-part message in MIME format. --------------060301040703090507090609 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit
Michael Bulatovich wrote:

</font></pre> <blockquote type="cite"> <pre wrap=""><font face="Arial">would you be money ahead to just make blocks of the windows? how many different types / sizes are there? </font></pre> </blockquote> <pre wrap=""><!----><font face="Arial"> I use a simple routine that draws windows in elevation to any size that I want with some control over the elements in them. In some work, window sizes are all custom, so blocks are to static and limiting. </font></pre> </blockquote> EXACTLY!<br> I would have so many blocks that finding the right block would be more work than drawing from scratch.<br> <br> Hit the wall this morning, I was hoping to use <font color="#3333ff">read-line</font> feeding into <font color="#3333ff">setq</font>, but it returns text.......<br> <br> howsoever, there is a tutorial at <a href="http://www.afralisp.net/lispa/lisp1.htm ">afralisp.net</a>&nbsp; that is being quite useful.<br> I still think the odds are in my favor of getting done by Monday.<br> <br> may miss some sleep.....<br> <br> seems that dear old Kenny has moved on. <br> many thanks to Kenny - for many years - good source of "stuff".<br> <br> all hail David, and the brunette on the right.<br> or the other right, I forget which.<br> </body> </html>
--------------060301040703090507090609--
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload

I used to write programs in basic that created drawings from basic information about the object, entered or stored in a file. The output was only dxf though.
Bob
Add pictures here
<% if( /^image/.test(type) ){ %>
<% } %>
<%-name%>
Add image file
Upload

Polytechforum.com is a website by engineers for engineers. It is not affiliated with any of manufacturers or vendors discussed here. All logos and trade names are the property of their respective owners.