[futurebasic] Re: [FB] [FB3] Region saving

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : May 2002 : Group Archive : Group : All Groups

From: Robert Covington <artlythere@...>
Date: Fri, 24 May 2002 01:58:35 -0400
>>I need to be able to save the contents of a Region handle for reloading
>>later.
>>
>>
>>The below demo shows that it works, however I am wondering what if any
>>pitfalls lurk, or if loading a regionhandle without benefit of FN NewRGN to
>>init it first will work fine?
>>
>>Actually, commenting out all but the reload (if the file already exists)
>>and loading it works fine without NewRGN.
>>
>>Just wondering.
>>
>Robert,
>
>I dont' have much first-hand knowledge of any of this, but I would say:
>
>* Fn NewRGN is for creating a new region; if you already have a region (on
>disk, for example), you don't need to create a new one in order to access
>it.

>* If you use WRITE FIELD to save your region, and READ FIELD to reload it,
>what you end up with is functionally identical to what you saved. (I say
>functionally, because the actual handle (address) is likely different.)

>* You can think of a region as a handle (relocatable block) containing a
>proprietary record type. The handle holds all the needed information to
>recreate the region shape, but otherwise, it's just a handle.

>* Your example shows that it works. It's fine. Don't sweat it. :-)
>
> e-e
> =J= a  y
>  "

Works real fine. Yep. Will be handy for a recent Selections item. But the
last thing I need is for the toolbox to give me a surprise party later. :)


Now , how can I flip all the coordinates in a region, so I can mirror it
across an axis?

I remember 2D Tedd saying he had a method for getting the coordinates out
of a region handle..I can't locate that snippet.

Would be useful to be able to mirror/flip a region, so you can work on a
different view easily, or paint a mirrored area.


rc