Path: utzoo!attcan!uunet!ncrlnk!ncr-sd!hp-sdd!hplabs!ucbvax!bloom-beacon!EXPO.LCS.MIT.EDU!rws From: rws@EXPO.LCS.MIT.EDU (Bob Scheifler) Newsgroups: comp.windows.x Subject: Re: default font id Message-ID: <8812071301.AA12833@EXPO.LCS.MIT.EDU> Date: 7 Dec 88 13:01:05 GMT References: <288@stan.com> Sender: daemon@bloom-beacon.MIT.EDU Organization: The Internet Lines: 22 Is there a good reason that the font identifier in the font structure returned from fontp = XQueryFont(dpy,XDefaultGC(dpy,scn))->gid) ; is not a valid font id? It's the same old (tired) argument about resource id allocation being a client responsibility, there's no a priori id to assign to it, it would require special mechanism (deemed unnecessary) to assign an id to it. In addition, attempting to extract the font identifier for a default gc returns a 0xffffffff If you are reaching into a gc, you are writing non-portable code. The gc structure in Xlib is supposed to be opaque, there is absolutely no guarantee about how it's implemented. which sometimes is accepted as a valid font identifier and sometimes is rejected If it succeeds, its probably a server bug.