Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!rochester!cornell!uw-beaver!mit-eddie!ll-xn!ames!ucbcad!ucbvax!ucdavis!egg-id!ui3!wsucshp!kinner From: kinner@wsucshp.UUCP (Bill Kinnersley ) Newsgroups: comp.sys.amiga Subject: Re: Clipping within a window. Message-ID: <160008@wsucshp.UUCP> Date: Sat, 27-Jun-87 10:46:57 EDT Article-I.D.: wsucshp.160008 Posted: Sat Jun 27 10:46:57 1987 Date-Received: Wed, 1-Jul-87 05:47:56 EDT References: <205@sugar.UUCP> Organization: WSU Computer Science Lines: 28 peter@sugar.UUCP (Peter DaSilva) writes: > I want to clip some text (or graphic) output to within the borders of a > simplerefresh window. What's the best way to do this? I know I can use > superbitmap with GZZ, but that's rather overkill for text only output. > That is, I guess, how do I set up a clipping rectangle of my own within a > window? Do as follows: struct Rectangle rect = {10, 10, 100, 100} /* or whatever */ struct Window *win; struct Region *reg; reg = NewRegion(); OrRectRegion(reg, &rect); InstallClipRegion(win->WLayer, reg); --- "Nesting is for the birds" --Bill Kinnersley USENET: ...!ucbvax!ucdavis!egg-id!ui3!wsucshp!kinner INTERNET: kinner%wsu@RELAY.CS.NET CSNET: kinner@cs1.wsu.edu MAIL: CS Dept, Washington State Univ, Pullman WA 99164-1210 PHONE: (509)332-3340