-
Content Count
2268 -
Joined
-
Last visited
-
Days Won
46
Everything posted by Fr0sT.Brutal
-
What is the best (fast) way of checking if a string is number?
Fr0sT.Brutal replied to wuwuxin's topic in Algorithms, Data Structures and Class Design
With all abovementioned number formats don't forget decimal separators that could be customized to ANY char and that a digit even could be something other than 0-9 https://en.wikipedia.org/wiki/List_of_numeral_systems -
YouTube playback & control using WebView2 on Delphi 7
Fr0sT.Brutal replied to Yaron's topic in Windows API
Then you'll have to download a video by yourself fully controlling HTTP headers and feed resulting data to video player component -
Launched video. Saw `break; case 1: a();` Closed video.
-
YouTube playback & control using WebView2 on Delphi 7
Fr0sT.Brutal replied to Yaron's topic in Windows API
How a browser component could be non-valid? They must be limiting all browsers then which doesn't happen obviously. Maybe server expects some headers to distinguish standalone browser from an embedded component, try to mimic them -
Make document - print - scan to image - send - manipulate image - send - OCR to text - read π
-
That's much simpler. PDF split to images - many tools can do it, f.ex. free PDF-XChange viewer. Then add your ID with image processing tool that allows batch processing (IrfanView is free and powerful). Then join images back to PDF - the same PDF-XChange viewer can do it too
-
active FTP confusion (how is this even possible?)
Fr0sT.Brutal replied to merijnb's topic in ICS - Internet Component Suite
Honestly, "active" FTP mode is ugly, it violates client-server relationships and not gateway-friendly. So IMHO it's used rather rarely. -
Thoughts on using begin end merely to limit inline var scope.
Fr0sT.Brutal replied to MarkShark's topic in RTL and Delphi Object Pascal
Looking at some " succinct " languages, I'd prefer verbosity... Perl `sub deleteDoubleDots($) { while($_[0] = m/\.\./) { $_[0] = s/\/[^\/]*\/\.\.//; } }` -
Is Graphics32 ready for Delphi 11 yet?
Fr0sT.Brutal replied to RCrandall's topic in Delphi Third-Party
Thanks. This completely changes the things π Now it's even more shameful for Borland/Emba to not support IF expressions in CodeInsight -
Is Graphics32 ready for Delphi 11 yet?
Fr0sT.Brutal replied to RCrandall's topic in Delphi Third-Party
I came to the same conclusion when I was using traditional COMPILER_XX_UP. Then I switched to my own implementation based on IFs so now I have neat {$IF CompilerVersion >= RAD_XE4} -
SmartPointer implementations, Pros's and Con's
Fr0sT.Brutal replied to Rollo62's topic in Algorithms, Data Structures and Class Design
IMHO for the purposes of eliminating some boilerplate LOCs in small (<=2 screens) subroutines the implementation doesn't matter much - any will do. If SP's are supposed to live in collections, that's completely different subject -
Tarray , uses unit not found :-(
Fr0sT.Brutal replied to FranzB's topic in Algorithms, Data Structures and Class Design
TArray<T> = array of T; XE2's System.pas... -
Thoughts on using begin end merely to limit inline var scope.
Fr0sT.Brutal replied to MarkShark's topic in RTL and Delphi Object Pascal
IMHO using blocks just for this purpose only adds visual noise and needlessly increases LOCs -
Is Graphics32 ready for Delphi 11 yet?
Fr0sT.Brutal replied to RCrandall's topic in Delphi Third-Party
These jungles of compiler IFDEFs are horrible but spread very widely. Necessity of updating the file with each new compiler version (that Emba bakes out each year) is very dumb. Alas, IF clauses that allow MUCH simpler code appeared too late (in D7) and they still aren't correctly supported by IDE's CodeInsight π -
Check if FDTable has any date-related built-in functions allowed in filters. If not, your solution is OK. Just beware of locale-defined date formats (refer to filter specs to find whether it uses fixed or locale-dependent format). You can also shorten the range construction: `(timefield >= dt) and (timefield < IncDay(dt, +1)`
-
Or take a look at https://github.com/Fr0sT-Brutal/Delphi_SChannelTLS which implements WinAPI-provided TLS over any socket and has ready-to-use implementation of ICS socket.
-
enable/disable the internet connection?
Fr0sT.Brutal replied to David Schwartz's topic in Windows API
You can disable tasks in Scheduler -
Write a report to your boss that antivirus wastes concrete amount of your well-paid time, with calculations: say 2 min for linking * 20 builds per day = 40 mins per day = 8.3% of daily work time = $ 0.083 * YourSalary per month.
-
regular expressions split text with different options
Fr0sT.Brutal replied to FranzB's topic in Algorithms, Data Structures and Class Design
From what you wrote, trivial Pos('MyWord', s) will do the job. Or you should define conditions more strictly. What could be inside brackets? What chars MyWord contains? You seem trying to extract function calls from a source file. Don't forget about comments if they're allowed -
GDI object leak and overflow when TImageList is on a frame
Fr0sT.Brutal replied to aehimself's topic in VCL
BTW, FastMM is able to dump the whole heap and, IIRC, even produce diffs between two dumps. This could help to find lost objects -
GDI object leak and overflow when TImageList is on a frame
Fr0sT.Brutal replied to aehimself's topic in VCL
Something could leak without a detectable leakage. for i in 1..MaxInt do TButton.Create(MainForm) these buttons will be freed on form close but they obviously leak -
Exception classes implementing interfaces
Fr0sT.Brutal replied to Wagner Landgraf's topic in RTL and Delphi Object Pascal
You're right, though your solution utilizes RTL facilities while mine is fully abstract -
Interfaces, Factories, Dependency Injection under D2007?
Fr0sT.Brutal replied to Javier TarΓ's topic in Algorithms, Data Structures and Class Design
Just to use these concepts you won't need generics... however I doubt there is any lib such as S4D based on old language features. Maybe you'll explain what you need all that stuff for? -
Traybar application, get the last active windows on desktop
Fr0sT.Brutal replied to mvanrijnen's topic in Windows API
I don't get it. You want a window that your app's window lays on? But you have traybar app so there should be no window visible.