An example of using a private heap:
Unit unit1; interfaceuses windows, messages, extensions, variants, classes, graphics, controls, forms, dialogs, stdctrls; Type tform1 = Class (tform) button1: tbutton; Procedure button1click (Sender:
The vartype function under the variants unit can obtain the variable type, but it returns only a number. You need to combine these constants defined in the System Unit:
Varempty = $0000; varnull = $0001; varsmallint = $0002; varinteger = $000
Both strcomp and stricomp compare the pchar string size functions, but the latter is case insensitive.
Unit unit1; interfaceuses windows, messages, sysutils, variants, classes, graphics, controls, forms, dialogs, stdctrls; Type tform1 = Class
Both strcopy and strecopy copy the source pchar string to the target pchar string, but the return value is different;
The first address of the result returned by strcopy and the end (#0) Address of the result returned by strecopy.
Unit unit1;
Strlcat is similar to strcat. The extra parameter of strlcat seems to be limiting the result length.
Unit unit1; interfaceuses windows, messages, sysutils, variants, classes, graphics, controls, forms, dialogs, stdctrls; Type tform1 = Class
Setrectempty: Empty the rectangle;
Isrectempty: determines whether the rectangle is empty;
The so-called rectangle is null, that is, the rectangle is region-free, or right.
Unit unit1; interfaceuses windows, messages, sysutils, variants,
Getclientrect and clientrect obtain the client rectangle of the window;
Getwindowrect and boundsrect are window rectangles;
In addition, there is a Windows. getclientrect (using the same method as getwindowrect, they are all API functions
Problem Source: http://www.cnblogs.com/del/archive/2008/05/02/1179416.html#1179645
A global variable can be initialized. If you do not initialize it, it will be automatically initialized;
A local variable cannot be initialized. Although you
Windows is a multi-task operating system, and a task is an application (Application
Program ), An application occupies a process; in a process, multiple threads can be run (so there are many "multi-thread programming" topics ).
For Win32,
For example, align edit1 text to the right:
Setwindowlong (edit1.handle, gwl_style, getwindowlong (edit1.handle, gwl_style) or es_right );
In this example:
Unit unit1; interfaceuses windows, messages, sysutils, variants, classes,
In this example:
Unit unit1; interfaceuses windows, messages, sysutils, variants, classes, graphics, controls, forms, dialogs; Type tform1 = Class (tform) Procedure formpaint (Sender: tobject); end; vaR form1: tform1; implementation {$ R *.
Getregiondata (RGN: hrgn; {region handle} P2: DWORD; {region data buffer size} P3: prgndata {regional data structure trgndata pointer, see the table below}): DWORD; {1} // If the trgndata structure is successfully returned, rename the _ rgndata
The following three methods are used to determine whether an object exists (assign value:
If OBJ nil then...
If Boolean (OBJ) then...
If assigned (OBJ) then...
Through the test below, the conclusion is that obj NIL is the slowest; Boolean (OBJ)
Problem Source: http://www.cnblogs.com/del/archive/2008/05/19/1089944.html#1203165
1. # This character can be represented by a character encoding followed by a decimal or hexadecimal character encoding;
For example, the character "a" is encoded in 6
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service