论坛


2011年4月14日 星期四

Direct2D (42) : 在文本布局中添加嵌入对象 IDWriteTextLayout.SetInlineObject()

万一| 万一的 Delphi 博客 |23:34:00

这段代码怎么也过不去了,反反复复找不到原因;有谁知道,万望提醒我一下。{错误在 101 行} unit Unit1; interface uses Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms, Dialogs, Direct2D, D2D1, Wincodec, ActiveX; type T...

Direct2D (42) : 在文本布局中嵌入图片 IDWriteTextLayout.SetInlineObject()

万一| 万一的 Delphi 博客 |23:34:00

这段代码怎么也过不去了,反反复复找不到原因;有谁知道,万望提醒我一下。上面是刚碰到错误时的求助信息;现在终于找到错误了:是 D2D1.pas 的代码有问题,修改方法如下:{ 1、把 D2D1.pas 中 4142 行中的 var 修改为 const 或者去掉 } function SetInlineObject(va...

Direct2D (41) : 文本命中测试 - IDWriteTextLayout.HitTestPoint()

万一| 万一的 Delphi 博客 |18:11:00

uses Direct2D, D2D1; var iTextLayout: IDWriteTextLayout; {构建 DWRITE_TEXT_RANGE 结构的函数} function DWriteTextRange(pos,len: Cardinal): TDwriteTextRange; begin Result.startPosition := pos; Result.length := len; end; {建立 IDWriteTextLayou...

Delphi Labs: DataSnap XE - Callbacks

Pawel Glowacki| Pawel Glowacki |14:28:08

I was always intrigued by a possibility of doing callbacks in client/server, distributed applications.?RAD Studio XE demos include "CallbackChannels" demo that shows how to use callbacks with different?DataSnap?communication protocols (TCP/IP, HTT...

关于开放数组的小练习

万一| 万一的 Delphi 博客 |10:50:00

{整数求和函数,使用指定类型的开放数组} function Fun1(arr: array of Integer): Integer; var n: Integer; begin Result := 0; for n in arr do Inc(Result, n); end; {整数、浮点数或布尔值的求和函数,使用无类型的开放数组} function Fun2(arr: array of...

Direct2D (40) : 分别设置 IDWriteTextLayout 中文本的颜色

万一| 万一的 Delphi 博客 |09:31:00

function SetDrawingEffect( const drawingEffect: IUnknown; //颜色接口; 该接口需自己定义和实现, 只要能存取颜色即可 textRange: TDwriteTextRange //要设置的范围 ): HResult; stdcall;测试代码:unit Unit1; interface uses Windows, Messages, SysU...

Delphi Labs: DataSnap XE - Callbacks

Embarcadero| CodeCentral Delphi Submissions |06:07:56

"Delphi Labs" Delphi XE DataSnap demo showing the most simple use of callbacks. Both client and server are VCL Forms applications. Demo covers broadcasting to a channel and notifying a specific callback.You can find more informat...

Delphi Labs: DataSnap XE - Callbacks

Embarcadero| EDN Delphi Feed |00:12:53