Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!oakhill!razdan From: razdan@chanakya.oakhill.uucp (Anshuman Razdan) Newsgroups: comp.windows.x Subject: Registered Actions coupled with KeyBoard Focus Message-ID: Date: 10 Jul 90 18:44:25 GMT Sender: news@oakhill.UUCP Distribution: comp.windows.x Organization: Motorola Inc., SPS CAD, Austin, Texas. Lines: 68 Hi, I have a interesting situation to which I cannot seem to find an answer. Although I am using the HP widgets, this seems to do more with toolkit actions rather than belonging to a widget set. Anyways, I have an application that has a text widget (permanent) for user I/O and keyboard input. The text widget occupies a small area of the application and is in the bottom 2/5th of the application as shown in the figure _________________________________________ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | _________________________________________ | | | Text I/O | | | _________________________________________ To make it easier on the users, I use XtKeyBoardFocus for the topmost widget (and therefore all the otherewidgets to text widget) so that no matter where the cursor is, the keyboard input willgo to the Text widget. So far so good. It works. Now what I want to do is add actions to various functionalities of the application. So in the defaults file I say mpost*TExttWidget.translations: F1 : Zoomin() where TexttWidget is the name of the text widget. I use XtAddActions to register thezoomin action with toolkit. Now the problem : When I use translations in defaults file it overwrites(or seems to override)the default translations that are in the text widget. Therefore resulting in that I cannot type in any letter in the text widget, with or without keyboard focus on. If I comment out the line in the defaults file every thing seems to be fine. Is there a way that both translations can live side by side. In other words augment the translations. Or is there another way to achieve the same thing. Please email me the pointers or hints or if your extremely kind to the solution or possible solution. Thanks in advance. -- Anshuman Razdan Motorola Sector CAD Internal: razdan@chanakya Austin Tx Internet: razdan@chanakya.sps.mot.com ****************************************************************** * * * PS: All opinions are my own and my employers have their own * * which of course, most probably, in all honesty, as far * * as I know, which sure is a guess, do not coincide with mine. * * * ******************************************************************