本文整理汇总了C#中Attributes.write方法的典型用法代码示例。如果您正苦于以下问题:C# Attributes.write方法的具体用法?C# Attributes.write怎么用?C# Attributes.write使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Attributes
的用法示例。
在下文中一共展示了Attributes.write方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: change
// render opcode 5 - change picture
/**
* @see <a href="XRenderChangePicture.html">XRenderChangePicture</a>
*/
public void change(Attributes attr)
{
Request request = new Request (display, render.major_opcode, 5,
5+attr.count ());
request.write4 (id);
request.write4 (attr.bitmask);
attr.write (request);
display.send_request (request);
}
示例2: Picture
// render opcode 4 - create picture
/**
* @see <a href="XRenderCreatePicture.html">XRenderCreatePicture</a>
* @see Render#create_picture(Drawable, Picture.Format,
* Picture.Attributes)
*/
public Picture(Render render, Drawable drawable, Format format,
Attributes attr)
: base(render.display)
{
this.render = render;
Request request = new Request (display, render.major_opcode, 4,
5+attr.count ());
request.write4 (id);
request.write4 (drawable.id);
request.write4 (format.id ());
request.write4 (attr.bitmask);
attr.write (request);
display.send_request (request);
}
示例3: create
// opcode 1 - create window
/**
* @param depth possible: {@link #COPY_FROM_PARENT}
* @param klass valid:
* {@link #COPY_FROM_PARENT},
* {@link #INPUT_OUTPUT},
* {@link #INPUT_ONLY}
*
* @param visual_id possible: {@link #COPY_FROM_PARENT}
* @see <a href="XCreateWindow.html">XCreateWindow</a>
*/
public void create(int border_width, int depth, int klass, int visual_id,
Attributes attr)
{
Request request = new Request (display, 1, depth, 8+attr.count ());
request.write4 (id);
request.write4 (parent.id);
request.write2 (x);
request.write2 (y);
request.write2 (width);
request.write2 (height);
request.write2 (border_width);
request.write2 (klass);
request.write4 (visual_id);
request.write4 (attr.bitmask);
attr.write (request);
display.send_request (request);
}