

Kazantsev Alexey
Members-
Content Count
26 -
Joined
-
Last visited
-
Days Won
2
Kazantsev Alexey last won the day on October 6 2024
Kazantsev Alexey had the most liked content!
Community Reputation
28 ExcellentRecent Profile Visitors
The recent visitors block is disabled and is not being shown to other users.
-
programmatically determine the edition of RAD Studio 12.3
Kazantsev Alexey replied to dmitrybv's topic in Delphi IDE and APIs
Look at https://docwiki.embarcadero.com/RADStudio/Alexandria/en/IDE_Command_Line_Switches_and_Options for bds.exe /ProductInfo:SKU -
Press [Update Local File Cache] in SDK Manager after libgtk-3-dev installed.
-
type TForm1 = class(TForm) ListView1: TListView; procedure FormCreate(Sender: TObject); procedure ListView1UpdateObjects(const Sender: TObject; const AItem: TListViewItem); procedure FormDestroy(Sender: TObject); private FCustomItem : TListViewItem; FBitmap : TBitmap; public { Public declarations } end; var Form1: TForm1; implementation {$R *.fmx} procedure TForm1.FormCreate(Sender: TObject); begin for var i := 1 to 25 do ListView1.Items.Add.Text := Format('item #%u', [i]); FCustomItem := ListView1.Items[4]; FCustomItem.Text := 'Custom Background Item'; var c := TAlphaColorRec.Orangered; TAlphaColorRec(c).A := 64; FBitmap := TBitmap.Create(8, 8); FBitmap.Clear(c); end; procedure TForm1.FormDestroy(Sender: TObject); begin FBitmap.Free; end; procedure TForm1.ListView1UpdateObjects(const Sender: TObject; const AItem: TListViewItem); begin if AItem = FCustomItem then begin var Bkgnd := TListItemImage.Create(nil); Bkgnd.ScalingMode := TImageScalingMode.Stretch; Bkgnd.OwnsBitmap := False; Bkgnd.Bitmap := FBitmap; AItem.View.Insert(0, Bkgnd); end; end; custom_bkgnd_item.zip
-
program Project1; {$APPTYPE CONSOLE} uses System.Rtti; type TvatIndividual = record DocumentNumber: string; TurnoverDate: TDate; PaymentDate: TDate; DocumentType: string; Year: integer; TurnoverDescription: string; TurnoverAmount: Currency; end; begin for var f in TRttiContext.Create.GetType(TypeInfo(TvatIndividual)).GetFields do WriteLn(f.ToString); ReadLn; end.
-
Features of using command line compilers for Android64, Linux64, MacOS64, iOS64.
Kazantsev Alexey replied to dmitrybv's topic in Cross-platform
You need to specify parameters --libpath and --syslibroot. Values can find in SDK Manager. -
You can register your own IFMXSystemFontService.
-
Delphi Parser/Compiler Limitation?
Kazantsev Alexey replied to Larry Hengen's topic in Algorithms, Data Structures and Class Design
Use ampersand operator, Luke. program Project2; {$APPTYPE CONSOLE} uses System.TypInfo; {$SCOPEDENUMS ON} type TEnums = (&TRY, &SHR, &XOR, &IS, &AS); begin WriteLn(GetEnumName(TypeInfo(TEnums), Ord(TEnums.SHR))); WriteLn(GetEnumValue(TypeInfo(TEnums), 'shr')); ReadLn; end. Output: SHR 1 -
How can I allocate memory without raising exceptions ?
Kazantsev Alexey replied to Marus's topic in General Help
You can use SysGetMem, SysReallocMem, SysFreeMem. -
Sorry for dirty adaptation spritz_bench.zip
-
Two cent about compilers performance by the example of spritz-c stream cipher implementation: 1. Delphi 11, Windows x86_64 (classic compiler), release 2. Delphi 11, Linux x86_64 (nextgen, LLVM based compiler), release 3. FreePascal 3.3.1, Linux x86_64, release
-
What the Delphi 11 version number after november patch ?
Kazantsev Alexey replied to William23668's topic in Delphi IDE and APIs
Try to check file version of your delphide280.bpl (or just run Delphi only, not RAD Studio) -
What the Delphi 11 version number after november patch ?
Kazantsev Alexey replied to William23668's topic in Delphi IDE and APIs
Some about build numbers: https://blogs.embarcadero.com/rad-studio-11-2-alexandria-patch-1-available/#Final_Note_The_Patch_is_Listed_in_the_About_Box -
Delphi 11 - Is MACOS defined in OSXARM64 platform?
Kazantsev Alexey replied to vfbb's topic in Delphi IDE and APIs
You don't need mac to compile units. Just use command line compiler to compile this unit: unit def; interface implementation {$if defined(MACOS)} {$message hint 'MACOS defined'} {$endif} end. -
10.4.1+ Custom Managed Records usable?
Kazantsev Alexey replied to Darian Miller's topic in RTL and Delphi Object Pascal
https://quality.embarcadero.com/browse/RSP-35397 -
Binary size, how-to make it smaller?
Kazantsev Alexey replied to Wil van Antwerpen's topic in General Help
The same example on 10.4.2: 1770kb, 1279kb, 456kb