Jump to content

Anders Melander

Members
  • Content Count

    2985
  • Joined

  • Last visited

  • Days Won

    167

Everything posted by Anders Melander

  1. The problem with sub-forums is that the most active people here doesn't really use them (is my impression, at least); They use the flat view where all posts are visible, ordered by activity date. And the ignore functionality of the forum doesn't work that well. Even if you ignore a user or a topic, you still get to see the topics and that they post. Unfortunately it's apparently beyond the Invision Community (the forum software) developers to implement a property ignore/mute/block function. It's been requested for ages. Usenet worked so much better.
  2. Anders Melander

    Copy a table from one database into another - [Solved]

    The solution you are trying is for MySQL and will not work with an Access database. Apart from that, possible solutions depends on your answers to Lars' questions.
  3. I actually don't mind on-topic advertisements that much. After all, it's no different than 3rd party vendors announcing their libraries and not really participating beyond that. We got a couple of those already *cough* TMS *cough*. What I do mind is the dishonesty of pretending to discuss a topic but actually only drive traffic to their site in order to harvest leads. It's trolling. I agree that the topic was interesting, and I actually started to write a reply describing our own experiences and solutions, but then I noticed that neither the post nor the page that it links to actually contain any useful information; It's just a long collection of keywords and the whole message can be accurately summarized as "updating code can be problematic". It doesn't contain any actual solutions and some of the things that it says are just plain nonsense. The other "articles" posted here and on their site are just more of the same: Here are some words, and now enter your name and email to get access to an article with more information on this topic that we just failed to say anything useful about. Wow! F*ck 'em. I think we should. We don't allow spam and this is spam - even if it pretends to be something else.
  4. Anders Melander

    Removing semi transparency in background compile window

    I'm guessing you inspected the run-time properties because this is what the form looks like in the binary (coreide370.bpl😞 object ProgressForm: TProgressForm Left = 201 Top = 114 ActiveControl = CancelButton BorderIcons = [] BorderStyle = bsDialog Caption = 'Compiling' ClientHeight = 340 ClientWidth = 580 Color = clBtnFace Font.Charset = DEFAULT_CHARSET Font.Color = clWindowText Font.Height = -12 Font.Name = 'Segoe UI' Font.Style = [] PopupMode = pmAuto OnActivate = FormActivate OnClose = FormClose OnCreate = FormCreate OnDestroy = FormDestroy OnShow = FormShow TextHeight = 15 ... end If it was a property stored in the form we could have disabled it with a custom resource module (e.g. coreide370.foo). Well, I guess we've all (those of us that knew about it) thought that the AlphaBlend feature was a cool thing (I've certainly been there) until we actually tried it. If only there was some easy way of getting feedback on stuff like that before you release it into the wild. If only...
  5. Anders Melander

    Removing semi transparency in background compile window

    It's being set in code at run-time (i.e. it's not just a property that we can patch on the form) so my best guess is that you'd need to intercept the Windows API call that turns it on. As far as I can tell there's no registry value to control it. I've used procmon to trace all registry access during IDE startup, and when the compile progress form is shown, and the only relevant entry being read was the one that controls background compilation.
  6. TL;DR: Send us your email address so we can try to sell you our services. Am I wrong?
  7. Anders Melander

    Removing semi transparency in background compile window

    https://www.google.com/search?q=delphi+semi+transparent+form which leads to https://docwiki.embarcadero.com/Libraries/en/Vcl.Forms.TForm.AlphaBlendValue Do your users a favor: Play around with it a bit and then never use it again
  8. Anders Melander

    Forum running slow

    LOL, nope. This is a losing battle. They'll only stop when the have enough money (read: never). The free Cloudflare plan could be a (temporary) solution but I'm not sure if it will block these particular bots.
  9. Anders Melander

    Removing semi transparency in background compile window

    More likely Star Wars. I don't think early Star Trek had anything like it.
  10. Anders Melander

    Removing semi transparency in background compile window

    I didn't bother looking. A full build of 2.5 million lines of code takes 30 seconds on my new system so I don't actually need the feature. But I can see that you're compiling C++ code so I guess your compile time is slightly longer 🙂
  11. Anders Melander

    Removing semi transparency in background compile window

    Yes! So annoying; The change nobody asked for and I immediately turned off background compile.
  12. ...which is what I use in my launcher script: Copy the base registry tree (e.g. HKCU\SOFTWARE\Embarcadero\BDS\37.0) to another tree (e.g. HKCU\SOFTWARE\Embarcadero\FooBar\37.0) Remove all entries from the Known Packages key, except those that start with $(BDSBIN) Add all the BPLs in the Packages subfolder to Known Packages Launch Delphi with -r to use my alternate registry path. I would love that! It can really clutter a library source folder when you have to keep all the units in one single folder just so the user doesn't have to add all the sub-folders to the search path.
  13. I don't explicitly handle dependent DLLs but... BPLs are basically just DLLs and, since one package can depend on another. I handle that by adding the package folders to the system search path. This also takes care of dependent DLLs. Note that the search path is altered only for the current session (read: the running Delphi IDE process), so the global environment isn't modified.
  14. I don't know what you mean. Everything is under revision control, including 3rd party source (for build) and package binaries (for design-time). Is that meant to impress? The whole system obviously works better for large projects than for small ones as it takes some time to prepare for use. I wouldn't bother with adhoc projects. Yes, but fortunately we no longer do things like we did in the 90s when Delphi was designed. Delphi has just completely failed to evolve in this area.
  15. Read what I wrote again. With the system I described, a project can be deployed and ready to use anywhere, by anybody, in minutes. You just need to have Delphi installed. We use the exact same setup with build servers (with only Delphi installed) and with team developers. Most developers just pull from the repo, start Delphi with the script and they are ready to go. No need to setup or install anything.
  16. Yes. Is that a problem? When I work on a project, I focus on that project. Whatever other projects, that I'm not working on, do is not relevant - even if they use the same 3rd party libraries (which they do - and for example DevExpress is something like 2500 files). Besides, if you are working under revision control (like you should) then you have to use local copies. Design-time is another problem. I let the libraries install to whatever location they want and put the dcp/bpl files where they want. So for example I have DevExpress installed in one global location for design-time support, but each project also have their own copy of the DevExpress source via a Git sub-module, because I need to have all the source under revision control. I only compile/link against the global copy for ad-hoc stuff or open source projects. For the few cases where I work on older version of a project, and need the correspond older version of the libraries at design-time, I launch Delphi with a custom setup via my DelphiLauncher script. But it's rare. I don't use library dcus shared between projects. I always compile against the source and place the generated dcus in ..\Lib\$(Platform)\$(Config) or something like that. I.e. paths relative to the project.
  17. My advise would be to not use global library paths at all, unless you absolutely have to. I generally use project library paths instead, keep paths relative to the project folder, and reference the source folders instead of the dcu folders. The advantage is that projects are self-contained and can easily be moved to another location or shared with others (e.g. a build server) via version control (3rd party libraries are included as Git sub-modules under the source folder).
  18. IMO the QC/QP votes are a useless metric as the votes are completely unqualified, the sample size is too small, and most people don't think about the consequences of their "choice". I seriously doubt that there are many that will have a use for it, but whatever; It probably took someone an hour to implement. I think what people really wanted was more what the OP asked for, but of course I can't know. Anyway, fair point about the refactoring/compile time check. Um... It will anyway. Constant expressions are evaluated at compile time.
  19. Yes, but it's pointless. And I'm sure that won't stop people from doing it anyway. Like, I once worked with a developer who consistently used Pred and Succ on integers but couldn't explain why he didn't just use -1 and +1. I paid for the whole language, so I'm going to use the whole language. Next up: The ValueOf function: function ValueOf<T>(Value: T): T; begin Result := Value; end;
  20. Anders Melander

    How to handle conflicting modal popups

    Assuming you meant modal dialogs or modal forms (a popup is usually something else - and not modal), with regard to the problematic form: Have you modified the value of the PopupMode property on the form? Do you set the Parent property of the form?
  21. Anders Melander

    for loop variable value after the loop

    But the exit is conditional so the loop value is only guaranteed to be known if the condition was met [*]. In the concrete example... for I := 0 to Collection.Count - 1 do if TListColumn(Collection.Items[I]).WidthType <= ColumnTextWidth then Break; Changed(I <> Collection.Count); ...the value of I will be undefined if all columns have WidthType > ColumnTextWidth which is the case where the code expects I = Collection.Count. *) I will concede that the phrasing of the help is ambiguous and that it's unclear if the loop value is defined even if the exit condition isn't met. FWIW, here's what Danny Thorpe had to say about it back in the day:
  22. Ah... Lovely. Still, TPerlRegEx optionally supports greedy/ungreedy mode. AFAIK TRegEx is always greedy. Just last week I implemented a simple C to Delphi converter for some generated C code an I had to use TPerlRegEx instead of TRegEx because I needed ungreedy matching.
  23. Or you could have just followed the link I provided 🙂: Note that there's also TPerlRegEx if you need Perl regular expressions (PCRE). PCRE has some additional features but is also a bit more complicated to use. YMMV. Beware of using . unescaped if you want to match the '.' character. Normally . matches any character but in this case it works because it's inside a [ ] list. If you want to match the '.' character then it's usually better to escape it like this: \.
  24. That's not what NameOf does: https://docwiki.embarcadero.com/RADStudio/Florence/en/What's_New#NameOf_Instrict_Function In short, there's no function to get the current function name. You can search these fora for various hacks, and I'm sure someone will post suggestions, but I wouldn't recommend any of them.
  25. Sounds like a good job for regex. You can use https://regex101.com/ to experiment with the data and different expressions. For example this is a simple solution against your test data: https://regex101.com/r/VHdo1k/1
×