Monday, October 25, 2010

delphi programming for instance - can be produced anywhere drag and drop toolbar


In the frequently-used software, such as photoshop, office, delphi, etc., we often can drag the toolbar to conduct operations related to the toolbar ---- will drag out the formation of an independent small window; or the number of toolbar for each combination! (These are the features that we often say that the DOCK), results as shown below:



DELPHI Toolbar

In fact, the use of DELPHI, or other visual programming tools (such as c + + builder, etc.) are easy to implement the above features! Next, we look through a small example of how it is implemented, where the use of programming tools for the Delphi!

Before starting an instance, we should note some stuff! (Some nonsense about the first ^ _ ^)

VCL visual components are supported DOCK features!
In delphi, all inherited from Tcontrol and TWinControl of VCL components, support dock feature.

Basically, the need for dock action requires at least two components, one component being attached to the dock site, the other components attached to the dock site. DELPHI provides visual components, only inherited from the TWinControl the VCL components that have the dock site features, and so long as the VCL components inherited from Tcontrol then have the function attached to the dock site.

* If you want a component inherited from TWinControl a dock site features, so long as the components of the property DockSite can be set to true;
* If necessary a component inherited from TControl attached to the dock site, as long as the property of Drag kind set to dkDock, DragMode property can be set to dmAutomatic,

When the program execution, you can use the mouse to drag the latter to the former components on the device, to dock action. As for the dock of the actual action are encapsulated in components, the user need not control how these actions are carried out.

Immediately begin our examples!

Create a common project (project1), drag pages from the win32 control a CoolBar, a ToolBar, an ImageList to the form1 form, the property is as follows:




Form1

. Caption: example of the realization of a DOCK functions;






CoolBar1 (to be attached to the dock site elements)

. AutoSize: true;
. DockSite: true;
For some better results, you can BorderWidth, EdgeBorders, EdgeInner, EdgeOuter, the associated set!



ToolBar1 (attached to the dock site components)
Right-click on the ToolBar1 components, select New Button, the new number of buttons between them can be New Separator, associated groups separated!

. Caption: tool bar (when the window is displayed independent of the title)
. AutoSize: true;
. DockKind: dkDock;
. DragMode: dmAutomatic;
. Flat: ture; (it look better)
. Images: ImageList1;
Similarly, for some better results, you can BorderWidth, EdgeBorders, EdgeInner, EdgeOuter, the associated set!



ImageList1,
Double-click the control, select Add ..., add the pieces of pictures. This can easily be in these pictures assigns ToolBar Button!



Click the Run button, you drag down your toolbar, you can not immediately see the results now? We have not written a line of code do? ? ? ? This is Delphi's powerful place!



[Next]



In order to better drag and drop, we add the following lines of code! (Mainly CoolBar1 the onDragOver, onDockDrop and UnDock events); source code is as follows (very short, do not think I'm lazy!) (Download the source files packaged with the implementation of the program)

unit sample1;

interface

uses
Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
ImgList, ComCtrls, ToolWin;

type
TForm1 = class (TForm)
ImageList1: TImageList;
CoolBar1: TCoolBar;
ToolBar1: TToolBar;
ToolButton1: TToolButton;
ToolButton2: TToolButton;
ToolButton3: TToolButton;
ToolButton4: TToolButton;
ToolButton5: TToolButton;
ToolButton6: TToolButton;
ToolButton7: TToolButton;
procedure CoolBar1DragOver (Sender, Source: TObject; X, Y: Integer;
State: TDragState; var Accept: Boolean);
procedure CoolBar1DockDrop (Sender: TObject; Source: TDragDockObject; X,
Y: Integer);
procedure CoolBar1UnDock (Sender: TObject; Client: TControl;
NewTarget: TWinControl; var Allow: Boolean);
procedure ToolButton1Click (Sender: TObject);
private
(Private declarations)
public
(Public declarations)
end;

var
Form1: TForm1;

implementation

($ R *. DFM)

procedure TForm1.CoolBar1DragOver (Sender, Source: TObject; X, Y: Integer;
State: TDragState; var Accept: Boolean);
begin
Accept: = (source = ToolBar1); file / / specify the conditions to accept drag and drop drag and drop objects to ToolBar1;
end;

procedure TForm1.CoolBar1DockDrop (Sender: TObject; Source: TDragDockObject;
X, Y: Integer);
begin
ToolBar1.AutoSize: = false; file / / when the device onto the dock site components above, and after release the left mouse button, this event will be the implementation of
ToolBar1.Align: = altop; file / / In order to facilitate drag and drop, the width and coolbar1 toolbar1 similar.
ToolBar1.Width: = CoolBar1.Width-1;
end;

procedure TForm1.CoolBar1UnDock (Sender: TObject; Client: TControl;
NewTarget: TWinControl; var Allow: Boolean);
begin
ToolBar1.AutoSize: = true; file / / when the components of a component off the dock site, the matter will be executed
ToolBar1.Caption: =''Toolbar''; file / / set the window size separate toolbar and the title
end;

procedure TForm1.ToolButton1Click (Sender: TObject);
begin
Close; file / / exit program
end;

end.

DOCK features listed below and related events:

OnDragDrop: When the device is drag, this event is executed;
OnDragOver: used to specify the components can be dragged conditions;
OnDockDrop: When the device onto the dock site components above, and after release the left mouse button, this event will be implemented;
OnDockOver: When the components of a device onto the dock site, this event will be implemented;
OnUnDock: When the components of a component off the dock site, the matter will be implemented;
OnGetSiteInfo: to obtain some information components dock site.

Well, drag and drop through a small example of the toolbar, we can immediately appreciate the power of Delphi's ease of use and Office! Later I will continue to write about programming with Delphi for instance the article! Members Delphi enthusiasts, we will Delphi be in the end it! NGA is limited, if any wrong with it, pointed out that users please! Thank you! aatun@163.net






Recommended links:



hal.dll damaged the Problems caused by Ubuntu not boot



Who is knocking THE door of opportunity?



Simple Food And Drink



how to upload put convert kodak playsport video to



Taobao Is Free Of Charge Commitment Charges Due To Question



Recommend Inventory And Barcoding



Quality control in the "Statistics" Several concepts



FLV To IPod



H.264 to AVI



MTS To MP4



Modify the secondary cache can not speed up XP



Ali Mama assets will pass into THE listed company Alibaba



Best Games Board



"Digital Tobacco" to Me



Sail a meteoric rise through media and public relations



Thunder won the Super Rabbit infringement compensable 80000



Monday, October 18, 2010

National Domain Name defeat ". COM"


Then something of value, if only shelved, also difficult to obtain public favor. CN domain name registration of the final volume to 5.3 million beyond the domestic COM domain names, its power is in the rich and wide range of applications.

Present, as Sina, Baidu, Sohu's fire performance of the Nasdaq in the United States, "China concept" strong impact with the international Internet community's attention, the most dazzling terms. However, the Internet's first side "flag" the rise is called lonely entrants, it is our familiar ". CN".

"Flag"

In the distant in October 1990, Professor Qian Tianbai behalf of the Chinese, the official in the Internet domain name registered distribution management center of China's top-level domain. CN, and established the first Chinese CN domain name server. Mysterious and strange at the time on the Internet, just as quietly plugging the side of "flag", from China has its own online identity.

聽聽聽 4骞村悗锛屼腑鍥藉叏鍔熻兘鎺ュ叆鍥介檯浜掕仈缃戯紝CN鍩熷悕鐨勯《绾ф湇鍔″櫒涔熺粨鏉熶簡鈥滄梾灞呪?寰峰浗鐨勫巻鍙诧紝姝e紡杩佸洖鍥藉唴銆?997骞碈N鍩熷悕娉ㄥ唽绠$悊鏈烘瀯鈥斺?涓浗浜掕仈缃戠粶淇℃伅涓績(涓嬬О鈥淐NNIC鈥?姝e紡缁勫缓锛孋N鍩熷悕鐨勫彂灞曠敱姝よ蛋鍑烘繁闄紝閫愭涓烘櫘閫氱綉姘戞墍鐔熸倝銆佹帴鍙椼?

聽聽聽 鍦–NNIC鎴愮珛涔嬪垵锛孋N鍩熷悕娉ㄥ唽閲忓彧鏈夊尯鍖?000鏉ヤ釜銆備絾鍒?005骞?鏈堬紝CN鍩熷悕娉ㄥ唽閲忓凡杈惧埌70澶氫竾涓紝鎴愪负浜氭床娉ㄥ唽閲忔渶澶х殑鍥藉椤剁骇鍩熷悕銆傚崐骞翠箣鍚庯紝CN鍩熷悕缁堜簬涓?妇绐佺牬鐧句竾锛屾垚涓哄叏鐞冪鍏ぇ鍥藉椤剁骇鍩熷悕銆傝繖涓?敞鍐岄噺鍦?006骞村勾搴曡鍒锋柊鍒?80澶氫竾涓紝鎺掑悕涔熶笂鍗囧埌涓栫晫绗洓浣嶃?

聽聽聽 鍘嗗彶鐨勬寚閽堝仠鐣欏湪2007骞?鏈堬紝CNNIC鍚戜笘鐣屽鍛婏紝CN鍩熷悕娉ㄥ唽鎬婚噺杈惧埌530涓囷紝澶у箙瓒呰秺COM鍩熷悕(Commercial organizations锛岀粍缁囧煙鍚?鍥藉唴娉ㄥ唽閲忥紝杩涘叆涓栫晫鍥藉椤剁骇鍩熷悕涓夌敳姒滃崟锛屽熀纭?祫婧愮殑寮哄娍鍙戝睍涓轰腑鍥戒簰鑱旂綉鍙戝睍娉ㄥ叆浜嗘柊鐨勫姪鎺ㄥ墏銆?br />
聽聽聽 鍏ㄦ皯鈥滅粌鍏碘?

聽聽聽 涓嶤N鍩熷悕鐨勮繀閫熷.澶х浉瀵瑰簲鐨勬槸锛?0骞翠箣鍓嶏紝涓浗浠呮嫢鏈?0涓囩殑缃戞皯锛?0骞翠箣鍚庯紝涓浗缃戞皯鏁伴噺鍒欑獊鐮翠簡1.4浜裤?鍏ㄦ皯鎬х殑搴旂敤淇冭繘CN鍩熷悕鍦ㄧ煭鏃堕棿鍐呭疄鐜颁簡澶ц法姝ョ殑璺宠穬寮忓彂灞曘?

聽聽聽 鍑轰簬瀵圭數瀛愭斂鍔″拰淇℃伅瀹夊叏鐨勯渶姹傦紝CN鍩熷悕鏈?棭鍦ㄦ斂搴滄満鏋勫緱鍒板箍娉涘簲鐢ㄣ?鍏ㄥ浗浜哄ぇ缃戙?涓浗鏀垮簻缃戙?鏂板崕缃戠瓑鍏崇郴鍥借姘戠敓鐨勭綉绔欓兘鍚敤浜咰N鍩熷悕浣滀负涓诲煙鍚嶏紝鍚勭骇鏀垮簻缃戠珯涔熺悍绾峰甫澶村姞寮哄煙鍚嶄娇鐢ㄨ鑼冿紝鐩墠楂樿揪97%鐨勭渷绾ф斂搴滅綉绔欏煙鍚嶈鑼冧娇鐢–N鍩熷悕銆傚幓骞村寳浜?008濂ヨ繍浼氭寮忓惎鐢╞eijing2008.CN涓诲煙鍚嶄篃涓?椂浼犱负浣宠瘽銆?br />
聽聽聽 鍦ㄦ斂搴滄満鏋勫惎鐢–N鍩熷悕鐨勭ず鑼冧笅锛屾捣灏斻?涓夋槦绛変紬澶氱煡鍚嶄紒涓氫竴娆℃?鏁扮櫨涓狢N鍩熷悕鐨勬敞鍐岃鍔ㄦ寲鎺樺嚭浜咰N鍩熷悕鐨勪环鍊兼墍鍦紱鑱斿悎鍒╁崕鎺ㄥ箍涓崕鐗欒啅鏃舵敞鍐寊hyg.cn鐨勮鍔ㄤ篃寮曞緱鍏朵粬浼佷笟鍦ㄦ帹骞挎椿鍔ㄤ腑鏁堜豢銆傚湪浜掕仈缃戝叕鍙稿拰鍥戒紒500寮虹瓑闆嗕綋鍚敤CN鍩熷悕琛屽姩鐨勫甫鍔ㄤ笅锛屾牴鎹潈濞佺粺璁★紝涓浗20涓富娴佽涓氫腑锛屽凡鏈?0%鐨勪紒涓氬惎鐢ㄤ簡CN鍩熷悕銆?br />
聽聽聽 鏀垮簻鍜屼紒涓氬CN鍩熷悕鐨勫簲鐢ㄧ粰缃戞皯鐨勭ず鑼冩晥搴旀槸宸ㄥぇ鐨勶紝杩欏姞閫熶簡澶т紬鍖栧簲鐢ㄧ殑鍒版潵銆傚緢澶氱綉姘戝紑濮嬩富鍔ㄥ皾璇曘?浣撻獙CN鍩熷悕鐨勫簲鐢紝骞跺湪鎺㈢储鍑烘柊鐨勫簲鐢ㄦā寮忥紝鍚稿紩鏇村鐨勪汉鍔犲叆锛屽舰鎴愪簡鑹?鐨勪簰鍔紝鐩存帴淇冭繘浜咰N鍩熷悕鐨勭垎鍙戙?

聽聽聽 CN澶у弽鏀?br />
聽聽聽 鐒惰?锛孋N鍩熷悕鐨勭垎鍙戠粷闈炴槸涓?绠?崟鐨勪豢鏁堣涓恒?

聽聽聽 鈥滀笉浠呭湪娉ㄥ唽鏉冪泭涓婃洿鏈変繚闅滐紝CN鍩熷悕鐨勬敞鍐屾墜缁篃鏇翠负绠?究蹇嵎銆佽闂洿涓虹ǔ瀹氥?鈥濅竴浣嶄粠COM鍩熷悕杞姇CN鍩熷悕搴旂敤鐨勬敞鍐岃?璇达紝瀵笴N鍩熷悕浠峰?鐨勯噸鏂拌璇嗭紝璁╀粬鎶涘純浜嗏?COM鍩熷悕鏄浗闄呯殑銆丆N鍩熷悕鏄浗鍐呯殑鈥濈殑閿欒瑙傚康銆?br />
聽聽聽 浣滀负CN鍩熷悕涓ゅぇ浠茶鏈烘瀯涔嬩竴锛屼腑鍥藉浗闄呯粡娴庤锤鏄撳鍛樹細鍩熷悕浜夎涓績绉樹功闀挎潕铏庤〃绀猴紝CN鍩熷悕鐢变腑鍥借嚜涓荤鐞嗭紝鍦ㄤ簤璁徊瑁佷腑閲囩敤涓枃璇█銆侀?鐢ㄤ腑鍥芥硶寰嬶紝鐩告瘮COM鍩熷悕鐢卞浗澶栨満鏋勪徊瑁佽?瑷?紝涓浗娉ㄥ唽鑰呭湪CN鍩熷悕浜夎涓幏鑳滃嚑鐜囪杩滆繙楂樺嚭锛岄伩鍏嶄簡鍦–OM鍩熷悕绾犵悍涓婇伃閬囩殑鍙嶅悜鍩熷悕鎺犲ず銆?br />
聽聽聽 鑰屾嵁CNNIC鎶?湳鎬荤洃鏉庢檽涓滀粙缁嶏紝涓轰簡瀹炵幇CN鍩熷悕璁块棶閫熷害鍜岀ǔ瀹氭?鐨勬彁楂橈紝CN鍩熷悕涓嶄粎鍦ㄥ幓骞村仛浜嗛噸鏂伴儴缃诧紝杩樹笌闊╁浗绛夊悎浣滃湪娴峰浜掓斁鏈嶅姟鍣紝鍒囧疄淇濋殰浜咰N鍩熷悕璁块棶鐨勭ǔ瀹氶珮鏁堛?杩戞湡锛孋NNIC姝e湪灏辨缇庤缃瓹N鍩熷悕灞曞紑璋堝垽锛屽苟鏈夋湜鎸鸿繘娆х編锛屼互鏂逛究娴峰鐢ㄦ埛璁块棶CN鍩熷悕銆?br />
聽聽聽 浣滀负涓浗浜掕仈缃戝熀纭?祫婧愶紝CN鍩熷悕鏄紒涓氱殑浜掕仈缃戝搧鐗屾爣璇嗭紝鏄腑鍥戒紒涓氶?寰?浗闄呭寲鐨勬ˉ姊侊紝涔熸槸璺ㄥ浗浼佷笟瀹炵幇鏈湡鍖栫殑閲嶈鎵嬫銆傚浜庝腑鍥藉箍澶х綉姘戞潵璇达紝CN鍩熷悕鍒欐槸浠栦滑涓嶅彲鎴栫己鐨勭綉缁滆韩浠借瘉锛屽洜涓哄畠浣撶幇浜嗕釜浜哄湪浜掕仈缃戜笂鐨勭嫭鏈夎韩浠姐?

聽聽聽 姣棤鐤戦棶锛孋N鍩熷悕杩欎簺浠峰?鍜岀壒鑹查?娓愯鍙戞帢鍜岃鍙紝鏄疌N鍩熷悕娉ㄥ唽閲忕獊鐮?30涓囥?鍦ㄥ浗鍐呰秴瓒奀OM鍩熷悕鐨勬牴鏈師鍥犮?

聽聽聽 鈥滀綔涓哄浗瀹跺煙鍚嶆敞鍐岀鐞嗘満鏋勶紝绠$悊缁存姢CN鍩熷悕鐨勮繍琛屾槸涓?釜閲嶈鑱岃兘锛屼篃鏄疌N鍩熷悕鍙戝睍鐨勫熀纭??鑰岃瀹炵幇CN鍩熷悕鍙戝睍鐨勭獊鐮达紝杩樺繀椤诲皧閲嶅競鍦鸿寰嬨?鈥滳NNIC鍔╃悊涓讳换鍒樺織姹熷鏄銆?br />





相关链接:



Shorewall simply set the single-user



Easy to use DOWNLOAD Managers



Flash The perfect lover



Recommend SERVER Applications



BT has been Closed, we see what?



DAT To 3GP



Review Strategy And War Games



MP4 TO Flash



AVI to MOV



P2P Popular Series Of Four



The Hai Lute: national, world's



HOT Flash Tools



Manufacturing integration trend MANUFACTURING and EMS has Approaching



1 Million For The Lessons Do Not Come!



Recognition by YOUR new company interviews



Quot the dynamic link library ipp.dll could not



Tuesday, October 5, 2010

"Aion" powerful sword star is said to cause litter



First, is the fear of many timid novice team destroy mission. They do not understand the Star Sword. Rubbish caused these tragic star sword.

Second, is the vulnerability created a demonic sword star tragedy. . . Most afraid of death because the Magic Way. . His most hated is the sword of his sleep strange constellations.

Third, the capacity of the team is too low. . The team are afraid of death. . Afraid of repair experience. . Resistance can not afford two or more of the blame. . . The tragedy was caused by the sword. . If the guard can play the four anti-strange. . If the Magic Way is not strange to see four run. . If the nanny is not strange to see the chaos of four. So. . The most powerful sword star will play a powerful force. . . What a spectacular and powerful. . .

Fourth, NC created a sword is Tragic star. . He created a sword to kill the heroic star of the group. . But the design of the monster it is can not touch II. .

5, is the most novice star rookie sword covered a few really strong, skilled sword stars. . Star of the tragedy caused by the sword. . .

Key:. . If guard against some more powerful. . Hatred bigger. . Pulling up around three blame their own side. . Strange sleep without Magic Way. . . The Magic Way to focus DPS output. . Nurse group added. . Constellation sword sweep. . Who dare say that the sword stars refuse. . . . .

I am the sword star attitude. . Is definitely positive and affirmative. . I have two swords asterisk. . A Magic Way number. . . .

Like to play swords sing. . . . But I can not kill people with swords sing. . . . Magic Way to serve on the train for my sword star revenge. .

Sword Star One (South China Telecom) Sword Star II (Southern Telecom) One Magic Way







Recommended links:



super scanner hand held metal Detector an ideal



Picked E-Mail Tools



Accelerator with the PP to see POTATOES, no buffer Youku



Shop DICTIONARIES Education



Ruiz: Barcelona will help AMD out of the doldrums



TOD to WMV



MENGNIU: standing on the crossroads?



Improvement of the current financial report



Easy to use Web Servers



An example of Style



UNDER the iceberg



Illustrator plug-in integrated use of (I)



WMV To MPEG



"Dalian Sigma Elevator" use EastFax



BOE Holdings East TPV regulators have not yet ratified Difficult



AVI to MOV