HDTenEightyP/NetNews huggingface dataset:
From: moore@cs.utah.edu (Tim Moore)
Subject: fred indentation
Organization: University of Utah CS Dept
Date: 29 Aug 92 07:30:06

Can you cutomize the indentation of lisp forms in fred? I've found 
*fred-special-indent-alist*, but that seems to specify the number of
forms that are special in a form. I don't want to change that, I want
to change the indentation of those "special" forms.

BTW, thanks to all for advice on what make to buy to run MCL. I bought
a Mac IIsi 5/80. I'm saving my pennies for more memory, but in the
meantime MCL runs very nicely on it.

I'm very impressed by MCL so far. I think it compares favorably with
Allegro Common Lisp and Lucid on much faster Unix machines. It's like
having a home Lisp machine!



 
--
Tim Moore                    moore@cs.utah.edu {bellcore,hplabs}!utah-cs!moore
"Wind in my hair - Shifting and drifting - Mechanical music - Adrenaline surge"
	- Rush
From: wilcox@cmns.think.com
Newsgroups: comp.lang.lisp.mcl
Subject: main-screen-color-p
Date: 26 Aug 92 15:04:51 GMT
Original-To: info-mcl@cambridge.apple.com

Here's a quick way to tell if the main screen can display in color:

(defun main-screen-color-p ()
  "Is the main screen capable of displaying color?"
  ;; *color-available* just tells you if color quickdraw is in ROM
  ;; it doesn't tell you if the screen can display in color
  ;; #_getmaindevice trap gives handle to screen containing menubar
  (let ((screen (#_getmaindevice))
        (gddevtype 0))
    (#_testdeviceattribute screen gddevtype)
    ))
From: molinari%executioner@ee.pitt.edu (Bert Molinari)
Newsgroups: comp.lang.lisp.mcl
Subject: Sys 7.0 compatability for v1.3.2
Date: 25 Aug 92 18:16:54 GMT
Original-To: info-macl@cambridge.apple.com


Sorry if this is a FAQ, but is there any generalized means of making an
application created with mcl 1.3.2 compatable with sys7?  Unfortunately I
don't know what the exact problems are, but i've been told that after opening
the application, the intro-window appears (that contains the name of the 
app), and the machine goes into gc and just crashes.

any ideas?

bert
Newsgroups: comp.lang.lisp.mcl
From: moore@cs.utah.edu (Tim Moore)
Subject: trap return result wierdness
Organization: University of Utah CS Dept
Date: 30 Aug 92 13:18:51

I'm new to MCL and somewhat new to Macintosh programming, so bear with me.

I was surprised by this result:
? (%stack-block ((response 4)) (#_gestalt #$gestaltEasyAccessAttr
 				          response))
59985

I was expecting a negative error number. Do I need to somehow coerce
the result of the trap into a negative word?

Also, is there higher level construct than %stack-block for allocating
a word or longword of storage?

--
Tim Moore                    moore@cs.utah.edu {bellcore,hplabs}!utah-cs!moore
"Wind in my hair - Shifting and drifting - Mechanical music - Adrenaline surge"
	- Rush
From: cartier@math.uqam.ca (Guillaume Cartier)
Newsgroups: comp.lang.lisp.mcl
Subject: Re: Yeah, what's a good CDRom drive?
Date: 26 Aug 92 14:00:07 GMT
Original-To: info-mcl@cambridge.apple.com (Macintosh Common Lisp)

>    From: moore@cs.utah.edu (Tim Moore)
>    Subject: What Mac should I get to run MCL 2.0?
>    Date: 10 Aug 92 16:30:34 GMT
>    [...]
>    What's a good CD-ROM drive?
>    [...]
>
>Yeah, what IS a good CDROM drive?  I have a IIfx with lots of memory
>and system 7.  Do I need to buy an interface card separately?
>
>-- Bob

I have been using Apple's AppleCD 150 for about
two weeks and have no complaints about it. With
it I was able to explore all of the wonders on
MCL's CD (and also play some nice music ;-)).

*********************************************************************
* Guillaume Cartier                 (514) 844-5294 (maison)         *
* L.A.C.I.M.                        (514) 987-4290 (bureau)         *
* Universite du Quebec a Montreal   (514) 987-8477 (telecopieur)    *
* Montreal, Quebec, Canada          cartier@math.uqam.ca (internet) *
*********************************************************************
From: dkozak@db.cray.com (Darryn Kozak)
Newsgroups: comp.lang.lisp.mcl
Subject: register-trap
Date: 27 Aug 92 22:04:26 GMT
Original-To: info-mcl@cambridge.apple.com


   I have some questions regarding the definition of fsopen below.  
   It is from the MCL 2.0f library/interface.lisp file, the file that 
   defines "not in ROM" toolbox and os routines from Inside Macintosh".
   In particular I'm interested in the call to ccl:register-trap.  Acording
   to Inside Mac. Volume VI, _HFSDispatch is trap #xA060.  ":a0 pb" 
   indicates that pb (the address of a :hparamblockrec) is put in register 
   :a0 as an argument to the call.  ":d0 26" indicates that 26 is to be put
   into register :d0.  The 26 is the selector (hex 1A), which, according to 
   Inside Mac again, selects one of the three routines OpenDF, PBHOpenDF or
   PBOpenDF. And "(:signed-integer :d0)" indicate the type of return value
   and where it will come from.  My questions now are:

   1. How do you know what registers to use for arg's?

   2. How do you know what registers to use for the selector?

   3. How do you know what registers to use for return values?

   4. Which routine will be called: OpenDF, PBHOpenDF or
      PBOpenDF? (and why?)

   5. Why is only one arg. (pb) supplied when OpenDF takes 3,
      PBOpenDF takes 2, and PBHOpenDF takes 2.

   6. What is the error code -50?  (I assume it means the trap call
      is not available.)

   7. Is this stuff documented somewhere?


   ; Returns two values instead of taking a var parameter
   ; 1) The refnum or NIL if error
   ; 2) The error code.
   (defun fsopen (filename vrefnum)
     (with-pstring-arg (namep filename)
       (ccl:rlet ((pb :hparamblockrec))
	 (setf (ccl:rref pb :hparamblockrec.ionameptr) namep
	       (ccl:rref pb :hparamblockrec.iovrefnum) vrefnum
	       (ccl:rref pb :hparamblockrec.ioMisc) (ccl:%null-ptr)
	       (ccl:rref pb :hparamblockrec.ioPermssn) 0
	       (ccl:rref pb :hparamblockrec.ioVersNum) 0)
	 (let* ((err (ccl:register-trap #xA060 :a0 pb :d0 26 (:signed-integer :d0)))
		refnum)
	   (if (eql err -50)
	     (setq err (#_Open pb)))
	   (setq refnum (ccl:rref pb :hparamblockrec.iorefnum))
	   (values (unless (eql refnum -1) refnum) err)))))


	   Thanks,

	   dk

   --
	   Darryn J Kozak			Cray Research Park
	   dkozak@cray.com			655E Lone Oak Drive
	   (612) 683-3610			Eagan, MN  55121
	   FAX (612) 683-3099		USA
From: mpradhan@medicine.adelaide.edu.au (Malcolm Pradhan)
Newsgroups: comp.lang.lisp.mcl
Subject: Re: main-screen-color-p
Date: 29 Aug 92 01:02:05 GMT
Organization: Faculty of Medicine, University of Adelaide
X-UserAgent: Nuntius v1.1.1d9
X-XXMessage-ID: <A6C50393D0013808@baldrick.medicine.adelaide.edu.au>
X-XXDate: Sat, 29 Aug 92 18:36:03 GMT

In article <9208261535.AA13352@media-lab.mit.edu> Henry Lieberman,
lieber@MEDIA-LAB.MEDIA.MIT.EDU writes:
>Main-Screen-Color-P still doesn't do it, I'm afraid. 
>On my machine, a color screen, it returns T, but when I set the
>Monitors control panel to black-and-white, it still returns T.
>
>I think what most programs will want to know is whether color pixels
>are actually reaching the user's retina, not if the screen has the
>"capability" in some sense to do color display.

 I think the best way to check for colour is first to see if the Mac
you're running on supports colour with Gestalt asking for
gestaltQuickdrawFeatures, test the result for gestaltHasColor.

 Then get the main screens gDevice using GetMainDevice and check
the current depth of the device by looking in the pixelSize field
of its gdPMap (ie the graphics device pixel map).

 Sorry, I don't have any lisp code for this but it isn't hard.
 
Regards,
Malcolm
_________________________________________________________________
    Malcolm Pradhan
    Medical Computing, Faculty of Medicine         _--_|\
    University of Adelaide, South Australia       /      \
    InterNet: mpradhan@medicine.adelaide.edu.au   \_.--x_/
    Fax: +618 223 2076  :x marks the spot:              v
From: bill@cambridge.apple.com (Bill St. Clair)
Newsgroups: comp.lang.lisp.mcl
Subject: Re: TIME, MCL and LOOPS (fwd)
Date: 27 Aug 92 22:16:53 GMT
Full-Name: Bill St. Clair
Original-To: bdrobert@MEDIA-LAB.MEDIA.MIT.EDU
Original-Cc: info-mcl

>Forwarded message:
>
>>From bdrobert@MEDIA-LAB.MEDIA.MIT.EDU Thu Aug 27 11:25:09 1992
>Message-Id: <9208271526.AA03549@media-lab.mit.edu>
>To: info-mcl-request@cambridge.apple.com
>Subject: TIME, MCL and LOOPS
>Date: Thu, 27 Aug 92 11:26:14 -0400
>From: bdrobert@MEDIA-LAB.MEDIA.MIT.EDU
>X-Mts: smtp

First I must slap your hand. Please send questions to info-mcl, not
info-mcl-request. info-mcl-request is for requests to be added or
removed from the info-mcl mailing list.

>
>Any suggestions on an easy way to have a function in your LISP program
>called, every X number of ticks or seconds, without doing a loop.
>I would like the program to be operating in other functions, and every
>so often, it would jump into a function, do stuff, and return to whatever
>task it was doing before.

The documented way of doing this is with *eventhook*. The undocumented
way is with ccl::%install-periodic-task. The former is documented in the
MCL 2.0 reference. The latter is used by the example file "thermometer.lisp":

ccl::%install-periodic-task name function interval &optional flags private-data
  Install or overwrite a periodic task with the given NAME (compared
  with EQ). Will cause FUNCTION to be funcalled with no arguments once
  every INTERVAL ticks (1/60 second). Flags defaults to 0 meaning call
  your function no matter what the context. If your function does drawing
  or should not be called while event processing is being done, you
  should use one or both (logior'd together) of the following values
  for FLAGS (both are defined in "ccl:library;lispequ.lisp" so you'll
  need to (require "LISPEQU") to use them):

  $ptask_draw-flag            Your periodic task does drawing
  $ptask_event-dispatch-flag  Your periodic task should not be called
                              during EVENT-DISPATCH.

  private-data is stored in the mac heap part of theperiodic task record,
  but this will not be useful unless you are writing an interrupt routine
  (in LAP or with the foreign function interface) that needs to interact
  with a periodic task (I'll give details to anyone who thinks they
  need to do this).

ccl::%remove-periodic-task name
  Remove the periodic task with the given name.
From: barmar@Think.COM (Barry Margolin)
Newsgroups: comp.lang.lisp.mcl
Subject: Correction to dpANS Common Lisp FTP instructions
Date: 24 Aug 92 01:52:25 GMT
Return-Path: <barmar@Think.COM>
Original-To: info-mcl@cambridge.apple.com, allegro-cl@ucbvax.berkeley.edu, clim@bbn.com,
        kcl@cli.com, lispworks@harlqn.co.uk

The previous announcement of anonymous FTP access to the dpANS for Common
Lisp gave the host name Beta.Xerox.COM.  Please correct that to
PARCFTP.Xerox.COM.  At the moment these are synonyms, but if Xerox were to
move their FTP server the latter name would move with it.  We're sorry for
the confusion.
From: berger@SOE.Berkeley.Edu (Daniel Berger)
Newsgroups: comp.lang.lisp.mcl
Subject: activating windows...
Date: 4 Sep 92 03:27:29 GMT
Original-To: info-mcl@cambridge.apple.com
X-Mailer: ELM [version 2.3 PL11]


Is it possible to have a window that is active (i.e. responsive to mouse 
actions - say selecting and dragging of icons), but not brought to the 
front?

dhb
From: lieber@MEDIA-LAB.MEDIA.MIT.EDU (Henry Lieberman)
Newsgroups: comp.lang.lisp.mcl
Subject: main-screen-color-p
Date: 26 Aug 92 15:35:14 GMT
Original-To: info-mcl@MEDIA-LAB.MEDIA.MIT.EDU


Main-Screen-Color-P still doesn't do it, I'm afraid. 
On my machine, a color screen, it returns T, but when I set the
Monitors control panel to black-and-white, it still returns T.

I think what most programs will want to know is whether color pixels
are actually reaching the user's retina, not if the screen has the
"capability" in some sense to do color display.
From: berger@SOE.Berkeley.Edu (Daniel Berger)
Newsgroups: comp.lang.lisp.mcl
Subject: table-dialog-item
Date: 25 Aug 92 23:46:02 GMT
Original-To: info-mcl@cambridge.apple.com
X-Mailer: ELM [version 2.3 PL11]


Here is a pretty silly question -

Is there a programable way to set the contents of a (single) cell of a
table-dialog-item or a sequence-dialog-item?  I do not want to set the
contents of the entire sequence (i.e., with set-table-sequence - I'd like
something like "set-cell-content"), as I do not know what the content is.
(I may be reading the content in from a file, and would like to create
the table first and fill the content as I go along).

Am I missing something obvious?

Daniel
From: djskrien@COLBY.EDU (Dale Skrien)
Newsgroups: comp.lang.lisp.mcl
Subject: Re: Interfacing to I/O boards
Date: 25 Aug 92 08:21:14 GMT
Original-To: info-mcl@cambridge.apple.com

>John Doleac wrote, in a message dated Wed, 12 Aug 1992 15:19-0400
>"I want to call C functions compiled using Symantec's Think C development
>system.
>...
>The manual tells how to use foreign function calls for code
>compiled by MPW.  This does not work for Think C.  Can anyone
>recommend a way to overcome this problem?"
>
>I believe there are two workarounds:
>1) If you have THINK Pascal, you can use it to create a library consisting of
>just your THINK C project. THINK Pascal libraries are the same as MPW object
>files, and can be used by MCL's FF loader.
>2) There is a user contribution on the MCL 2.0 CD-ROM that seems to have
>something to do with loading FF code directly from a THINK C project file. I
>can't vouch for this, as I don't own THINK C, but it's worth a look.
>

A third method is to use CODE resources.
I have used THINK Pascal to create functions which are then compiled by
THINK into CODE resources.  These resources can then be called from MCL by
using ff-call.  The same could be done in THINK C.
From: yost@adobe.com (David Yost)
Newsgroups: comp.lang.lisp.mcl
Subject: Re: A better "Fred Commands" help window
Date: 26 Aug 92 05:39:44 GMT
Organization: Adobe Systems Incorporated

In article <9208260012.AA10718@MIT.EDU> cfry@MIT.EDU (Christopher Fry) writes:
> As the originator of the Fred Commands window, I'd like to state
> that Yost's formatting is a definate improvement on mine. [Thanks David!]

Thank you.  I was wondering if anyone cared.
It's nice to hear praise from the person
whose work you hope you've approved upon.
And I agree with your suggestions.

One more thing: The list should appear twice.
The first time the commands should be grouped by type of function
The second time they should be sorted by key sequence as they are now.

> A nice extension would be to put a sentence of documentation in a 3rd
> column to the right.  For instance, the meaning of "ed-yank" might not
> be obvious to the new user but a short description of it would clear up
> misunderstandings.

Would you volunteer to do this?  I'm new to Fred and emacs.

 --dave yost
From: brainard%psych@hub.ucsb.edu
Newsgroups: comp.lang.lisp.mcl
Subject: Passing arrays to C
Date: 3 Sep 92 00:18:48 GMT
Original-To: info-mcl@cambridge.apple.com


Hi,

We are trying to port a bunch of code to MCL.  The
code relies heavily on C routines to crunch numbers
in multi-dimensional arrays.  We are trying to figure
out how to pass such arrays to C.  Ideally, the
C routine would just receive a pointer to the data
and separately the dimensions of the array.

  a) Is there any documentation on the exact structures
  used to store multidimensional arrays in Lisp?  (The
  documentation is pretty vague on this point.)

  b) Is there any good (or bad) way to get a pointer
  to the actual array data and hand that off to C?

Thanks,

David Brainard
Department of Psychology
University of California
Santa Barbara, CA 93106
brainard@psych.ucsb.edu
(805) 893-2011
From: hall@allegra.att.com (Bob Hall)
Newsgroups: comp.lang.lisp.mcl
Subject: re: Yeah, what's a good CDRom drive?
Date: 27 Aug 92 13:05:54 GMT
Original-To: info-mcl@cambridge.apple.com

Thanks everyone for the responses.  Here is a summary:

Enthusiasm seems to be running high for the
NEC CD-74 -- ClubMac (1-800-258-2622), EduCorp (1-800-843-9497),
            and Tiger Software (1-800-666-2562)
  Prices seem to be around $570-600 for the naked drive, but it
  comes bundled with a bunch of sw and speakers (for 1-3 hundred more)
  that might be worthwhile, depending on your interests.
  This is claimed to be "fast"

Also reported
AppleCD 150 -- from Apple.  "no complaints" -anon
  no reports on price/speed.

-- Bob
From: bill@cambridge.apple.com (Bill St. Clair)
Newsgroups: comp.lang.lisp.mcl
Subject: Re: Lisp Listener hidden
Date: 31 Aug 92 16:57:11 GMT
Full-Name: Bill St. Clair
Original-To: jipan@gmuvax2.gmu.edu (Jiqian Pan)
Original-Cc: info-mcl

>Does anyone know how the Lisp Listener is hidden while a MCL
>application runs?  It seems to me the MCL does not provide
>the function for the Lisp Listener.  Is that right?  Thanks.
>
>-JP

The listener is created whenever input or output is done on the default
value of the following streams:

*terminal-io*
*debug-io*
*query-io*
*standard-output*
*standard-input*
*error-output*
*trace-output*

The function BINHEX-TOPLEVEL in the file "ccl:examples;binhex;binhex.lisp"
illustrates binding *terminal-io*, *debug-io*, and *standard-output* to
a bit bucket stream to prevent the appearance of the listener.
From: ranson@LANNION.cnet.fr (Ranson)
Newsgroups: comp.lang.lisp.mcl
Subject: Re:  Am I black-and-white yet?
Date: 4 Sep 92 08:11:00 GMT
X400-Received: by /PRMD=inria/ADMD=atlas/C=FR/;
	Relayed; 04 Sep 92 08: 11:07+0200
X400-Received: by /PRMD=CNET/ADMD=ATLAS/C=FR/;
	Relayed; 04 Sep 92 08: 11:00 GMT
Original-To: info-mcl@MEDIA-LAB.MEDIA.MIT.EDU, lieber@MEDIA-LAB.MEDIA.MIT.EDU
Original-Cc: ranson@lannion.cnet.fr

What if you have a b&w AND a color screen?
     Daniel.
From: bill@cambridge.apple.com (Bill St. Clair)
Newsgroups: comp.lang.lisp.mcl
Subject: Re: main-screen-color-p
Date: 26 Aug 92 17:06:34 GMT
Full-Name: Bill St. Clair
Original-To: wilcox@cmns.think.com, Henry Lieberman <lieber@MEDIA-LAB.MEDIA.MIT.EDU>
Original-Cc: info-mcl

>Date: Wed, 26 Aug 92 11:04:51 EDT
>From: wilcox@cmns.think.com
>To: info-mcl@cambridge.apple.com
>Subject: main-screen-color-p
>
>Here's a quick way to tell if the main screen can display in color:
>
>(defun main-screen-color-p ()
>  "Is the main screen capable of displaying color?"
>  ;; *color-available* just tells you if color quickdraw is in ROM
>  ;; it doesn't tell you if the screen can display in color
>  ;; #_getmaindevice trap gives handle to screen containing menubar
>  (let ((screen (#_getmaindevice))
>        (gddevtype 0))
>    (#_testdeviceattribute screen gddevtype)
>    ))

If you run this code on a machine where *color-available* is NIL,
it will crash. Better would be:

(defun main-screen-color-p ()
  "Is the main screen capable of displaying color?"
  ;; *color-available* just tells you if color quickdraw is in ROM
  ;; it doesn't tell you if the screen can display in color
  ;; #_getmaindevice trap gives handle to screen containing menubar
  (and *color-available*
       (let ((screen (#_getmaindevice))
             (gddevtype 0))
         (#_testdeviceattribute screen gddevtype)
         )))

>Date: Wed, 26 Aug 92 11:35:14 -0400
>From: Henry Lieberman <lieber@MEDIA-LAB.MEDIA.MIT.EDU>
>To: info-mcl@MEDIA-LAB.MEDIA.MIT.EDU
>Subject: main-screen-color-p
>
>
>Main-Screen-Color-P still doesn't do it, I'm afraid. 
>On my machine, a color screen, it returns T, but when I set the
>Monitors control panel to black-and-white, it still returns T.
>
>I think what most programs will want to know is whether color pixels
>are actually reaching the user's retina, not if the screen has the
>"capability" in some sense to do color display.

It does the right thing in my hardware setup. Changing between 256 colors
and 256 grays toggles the value returned. I've got an 8*24 GC board
going to my color monitor. Maybe your monitor interface hardware is
doing the wrong thing.

For those of you with CD-ROM drives, there are a number of unexported
functions having to do with graphics devices at the end of the file:

   "MCL 2.0 CD:Additional MCL Source Code:Lib:color.lisp"
From: poeck@informatik.uni-wuerzburg.de (karsten poeck)
Subject: Re: files-in-directory
Followup-To: comp.lang.lisp.mcl
Organization: university of wuerzburg
Date: Thu, 27 Aug 1992 08:07:43 GMT

In article <EeafXB200iUx4_kZIQ@andrew.cmu.edu>, sr0o+@andrew.cmu.edu
(Steven Ritter) wrote:
> 
> I have just moved to a quadra, so I'm moving from MCL 1.3.2 to 2.0
> (beta). Some of my code uses a function called files-in-directory, which
> returns a list of files in the specified directory. I can't find
> anything similar in 2.0. Is there an equivalent? Are there lots of other

Try

(defun b=erzeuge-String (irgendetwas)
  "Ausgabe: macht aus irgendwas einen String, nil wird zu \"\""
  ;Autor: Karsten
  (cond   ((keywordp irgendetwas)(format nil "~s" irgendetwas))
          ((null irgendetwas) "")
          ((symbolp irgendetwas) (string irgendetwas))
          ((stringp irgendetwas) irgendetwas)
          ((typep irgendetwas 'Character)(string irgendetwas))
          (t (format nil "~a" irgendetwas))))


(defun b=konkateniere-nach-String (&rest Parameter)
  "Eingabe: Beliebig viele Parameter vom beliebigen Typ
  Ausgabe: Konkatenierter String"
  ;Autor: Karsten        
  (reduce #'(lambda(a b)
             (concatenate `string a b))
          (mapcar #'(lambda(was)
                     (if (stringp was)
                       was
                       (b=erzeuge-string was)))
                  parameter)))

(defun files-in-directory (was)
  (directory (b=konkateniere-nach-string was "*")
             :files t
             :directories nil))

(defun directories-in-directory (was)
  (directory (b=konkateniere-nach-string was "*")
             :files nil
             :directories t))

> differences between 1.3.2 and 2.0? Sorry I don't have any documentation
The whole window package is different,  object lisp is replaced by clos
cltl1 is replaced by cltl2
> -- CMU has a site license. Also, does the final version of 2.0 run on
> the quadra with the cache on?
> 
YES, fine
> Steve

Karsten
From: sr0o+@andrew.cmu.edu (Steven Ritter)
Newsgroups: comp.lang.lisp.mcl
Subject: files-in-directory
Date: 25 Aug 92 14:48:45 GMT
Article-I.D.: andrew.EeafXB200iUx4_kZIQ
Organization: Doctoral student, Psychology, Carnegie Mellon, Pittsburgh, PA

I have just moved to a quadra, so I'm moving from MCL 1.3.2 to 2.0
(beta). Some of my code uses a function called files-in-directory, which
returns a list of files in the specified directory. I can't find
anything similar in 2.0. Is there an equivalent? Are there lots of other
differences between 1.3.2 and 2.0? Sorry I don't have any documentation
-- CMU has a site license. Also, does the final version of 2.0 run on
the quadra with the cache on?

Steve