Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #32015

Re: Graphics wordset primitive semantics survey - filled/stroked

From "Rod Pemberton" <dont_use_email@xnothavet.cqm>
Newsgroups comp.lang.forth
Subject Re: Graphics wordset primitive semantics survey - filled/stroked
Date 2014-06-28 15:00 -0400
Organization Aioe.org NNTP Server
Message-ID <op.xh6hqfyx6zenlw@localhost> (permalink)
References <e9982e1e-c1a2-4de2-8c5d-94ba25aec319@googlegroups.com>

Show all headers | View raw


On Fri, 27 Jun 2014 11:24:09 -0400, Roger Levy <roger.levy@gmail.com>  
wrote:

> I'm working on a component for drawing graphics primitives, called  
> PencilBox.
>
> This is a survey to find out about opinions regarding the semantics of  
> drawing filled and stroked primitives.
>
> A)
> : filled ( -- )
> 0 0 at   filled   100 200 draw-box
> \ if FILLED is omitted, primitives are drawn stroked.
> 0 0 at            100 200 draw-box
>
>
> B)
> 0 0 at            100 200 draw-box
> 0 0 at            100 200 draw-boxf
>
>
> C)
> 0 0 at            100 200 draw-box
> 0 0 at            100 200 draw-box-filled
>
>
> D)
> 0 0 at            100 200 draw-box-stroked
> 0 0 at            100 200 draw-box-filled

Well, first, I'm not a "real" Forth programmer, but I don't like
the "at".  I'd like all four numbers together, at once, and an
ability to update some of them later.

Second, did you specify if "100 200" was a set of two points,
or a set of two offsets, e.g., width, height?

I'd rather that "0 0" be a point and "100 200" be lengths relative
 from that point.  The reason is so that the initial corner of the
box can change without having to update a second set of points.
I.e., by having "100 200" be lengths, not another set of corner
points, you can move around a fixed size box by updating a single
point, not two points.

E.g., for a 100x200 box with origin at 10,10 which form is it?

10 10 at    110 210 draw-box  \ 110 210 are a corner point
10 10 at    100 200 draw-box  \ 100 200 offsets from 10 10


Rod Pemberton

Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Graphics wordset primitive semantics survey - filled/stroked Roger Levy <roger.levy@gmail.com> - 2014-06-27 08:24 -0700
  Re: Graphics wordset primitive semantics survey - filled/stroked AKK <akk@nospam.org> - 2014-06-27 19:51 +0200
    Re: Graphics wordset primitive semantics survey - filled/stroked Roger Levy <roger.levy@gmail.com> - 2014-06-27 08:55 -0700
  Re: Graphics wordset primitive semantics survey - filled/stroked Roger Levy <roger.levy@gmail.com> - 2014-06-27 09:02 -0700
  Re: Graphics wordset primitive semantics survey - filled/stroked bruce.mcfarling@gmail.com - 2014-06-27 16:02 -0700
    Re: Graphics wordset primitive semantics survey - filled/stroked Roger Levy <roger.levy@gmail.com> - 2014-06-27 16:54 -0700
      Re: Graphics wordset primitive semantics survey - filled/stroked bruce.mcfarling@gmail.com - 2014-06-27 17:44 -0700
        Re: Graphics wordset primitive semantics survey - filled/stroked Roger Levy <roger.levy@gmail.com> - 2014-06-27 19:30 -0700
          Re: Graphics wordset primitive semantics survey - filled/stroked bruce.mcfarling@gmail.com - 2014-06-27 22:42 -0700
            Re: Graphics wordset primitive semantics survey - filled/stroked albert@spenarnc.xs4all.nl (Albert van der Horst) - 2014-06-28 11:50 +0000
  Re: Graphics wordset primitive semantics survey - filled/stroked "Elizabeth D. Rather" <erather@forth.com> - 2014-06-27 14:51 -1000
    Re: Graphics wordset primitive semantics survey - filled/stroked Roger Levy <roger.levy@gmail.com> - 2014-06-27 19:55 -0700
      Re: Graphics wordset primitive semantics survey - filled/stroked "Elizabeth D. Rather" <erather@forth.com> - 2014-06-27 17:23 -1000
        Re: Graphics wordset primitive semantics survey - filled/stroked Roger Levy <roger.levy@gmail.com> - 2014-06-27 22:12 -0700
          Re: Graphics wordset primitive semantics survey - filled/stroked "Elizabeth D. Rather" <erather@forth.com> - 2014-06-27 21:16 -1000
      Re: Graphics wordset primitive semantics survey - filled/stroked bruce.mcfarling@gmail.com - 2014-06-27 23:17 -0700
      Re: Graphics wordset primitive semantics survey - filled/stroked albert@spenarnc.xs4all.nl (Albert van der Horst) - 2014-06-28 11:58 +0000
  Re: Graphics wordset primitive semantics survey - filled/stroked Paul Rubin <no.email@nospam.invalid> - 2014-06-28 11:54 -0700
  Re: Graphics wordset primitive semantics survey - filled/stroked "Rod Pemberton" <dont_use_email@xnothavet.cqm> - 2014-06-28 15:00 -0400
    Re: Graphics wordset primitive semantics survey - filled/stroked BruceMcF <agila61@netscape.net> - 2014-06-28 12:59 -0700

csiph-web