Bug 37624 - parameter x is missing from synopsis of XDrawString in libX11.html#Drawing_Text
Summary: parameter x is missing from synopsis of XDrawString in libX11.html#Drawing_Text
Status: RESOLVED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Documentation (show other bugs)
Version: 7.6 (2010.12)
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: Xorg Project Team
QA Contact: Xorg Project Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-26 05:01 UTC by Christopher Yeleighton
Modified: 2011-10-15 15:58 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Christopher Yeleighton 2011-05-26 05:01:11 UTC
Current text: 

XDrawString(   *display,    
      d,    
      gc,    
      y,    
      *string,    
      length);   
  Display *display;
Drawable d;
GC gc;
intx, y;
char *string;
int length;

Expected text:

XDrawString (display, d, gc, x, y, string, length);   
Display *display;
Drawable d;
GC gc;
int x, y;
char const string [];
int length;
Comment 1 Alan Coopersmith 2011-05-27 20:15:51 UTC
I'm not sure what version you're looking at with ancient K&R declarations, but
http://www.x.org/releases/X11R7.6/doc/libX11/specs/libX11/libX11.html#Drawing_Text
currently has:

XDrawText(Display *display, Drawable d, GC gc, intx, y, XTextItem *items, int nitems);

The x is incorrectly marked as part of the parameter type, run together with y.
That's an easy fix to the docbook markup:

diff --git a/specs/libX11/CH08.xml b/specs/libX11/CH08.xml
index 3d69b14..5f450fe 100644
--- a/specs/libX11/CH08.xml
+++ b/specs/libX11/CH08.xml
@@ -4744,7 +4744,8 @@ To draw 8-bit characters in a given drawable, use
   <paramdef>Display<parameter> *display</parameter></paramdef>
   <paramdef>Drawable<parameter> d</parameter></paramdef>
   <paramdef>GC<parameter> gc</parameter></paramdef>
-  <paramdef>intx,<parameter> y</parameter></paramdef>
+  <paramdef>int<parameter> x</parameter></paramdef>
+  <paramdef>int<parameter> y</parameter></paramdef>
   <paramdef>char<parameter> *string</parameter></paramdef>
   <paramdef>int<parameter> length</parameter></paramdef>
 </funcprototype>

which makes it render as:
XDrawString(Display *display, Drawable d, GC gc, int x, int y, char *string, int length);

Fix checked into git as commit 6841260c8bb15404a0b4805bee3b0bdfec7176b3.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.