Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!umich!yale!think!snorkelwacker!bloom-beacon!EXPO.LCS.MIT.EDU!kit From: kit@EXPO.LCS.MIT.EDU (Chris D. Peterson) Newsgroups: comp.windows.x Subject: Re: Writing new Widgets under Athena. Message-ID: <9002052049.AA06063@expo.lcs.mit.edu> Date: 5 Feb 90 20:49:16 GMT References: <1990Feb5.013524.26667@agate.berkeley.edu> Sender: daemon@athena.mit.edu (Mr Background) Organization: The Internet Lines: 40 > Specifically, I want to set the border > width and border color on my new widget. My widget is a subclass of Core, > and Simple. A widget writer can set the default border width for his widget to be a different value than the one specified in core by just adding a line in the new widget's resource list for border width. Take a look at the width resource specification that is used by the Athena Text widget. An application writer can either use XtSetValues() or an app-defaults file, or fallback resources (R4 only) to set the border width for a widget. A user can set the border width with a line in his resource file (assuming that the application writer did not hard code in the value with XtSetValues()). > I set the resource: > MyProg*borderWidth: 5 > Then every widget in my application but mine gets a 5 pixel border width. This is exactly what is expected, you told that Application to set the border width to five pixels for each widget in your application. If you wanted to specify the border width for a specific widget then use a line like this: Myprog*myWidget.borderWidth: 5 or this Myprog.grandParent.parent.myWidget.borderWidth: 5 Take a look at ``doc/tutorials/resources.txt'' and the Athena Widget set manual section 2.9.2.1. Chris D. Peterson MIT X Consortium Net: kit@expo.lcs.mit.edu Phone: (617) 253 - 9608 Address: MIT - Room NE43-213