Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 10/11/23 in all areas

  1. THeY fouND tHe cOdE On ThE InTeRwebS. It muST be ThE beSTESt!
  2. Alexander Sviridenkov

    Unit dependency viwer

    Unit dependency viewer for Delphi - small tool created using HTML Component Library and ForceAtlas2 algo. https://delphihtmlcomponents.com/graph.rar Video:
  3. Christophe E.

    ANN : TECNativeMap 5.1

    TECNativeMap is a 100% Delphi mapping component using neither browser nor javascript. It is available in VCL and FMX for all platforms. Main new features of the last version Google 2DTiles API support Map and routing support from PTV Group Enhanced color filter with dark and bright theme You can download a trial version for Delphi 11
  4. Not so fast - it more likely was some AI that learned it from those sources - soon all loops will be written that way! The problem is that apparently whoever implemented it that way in the VCL did not even care to apply their style guide to the code. And I am not even going into the legal ramifications of Embarcadero copying code from the internet and then putting it under their copyright.
  5. Christophe E.

    ANN : TECNativeMap 5.1

    A basic way of displaying the radar image is as follows WMS : TECShapeMarker; WMS_Layer : TECNativeLayer; ... procedure TForm6.FormCreate(Sender: TObject); begin WMS_Layer := TECNativeLayer.Create(map,'WMS_dwd.de'); WMS := WMS_Layer.Shapes.AddMarker(0,0); WMS.WaitAnimation := false; WMS_Layer.Observer.OnMapEndMove := MapEndMove; WMS_Layer.Visible := true; end; procedure TForm6.FormDestroy(Sender: TObject); begin WMS_Layer.Free; end; procedure TForm6.MapEndMove(Sender: TObject); begin WMS.filename := 'https://maps.dwd.de/geoserver/dwd/wms?service=WMS&version=1.1.0&request=GetMap&layers=dwd%3ANiederschlagsradar&transparent=TRUE&SRS=EPSG:4326&BBOX='+doubletostr(map.SouthWestLongitude)+'%2C'+doubletostr(map.SouthWestLatitude)+'%2C'+doubletostr(map.NorthEastLongitude)+'%2C'+doubletostr(map.NorthEastLatitude)+'&width='+inttostr(round(map.width))+'&height='+inttostr(round(map.height))+'&styles=&format=image/png'; WMS.SetBounds(map.NorthEastLatitude, map.NorthEastLongitude, map.SouthWestLatitude, map.SouthWestLongitude); WMS.fitBounds := true; end; Basically, we use a marker that fills the entire map and displays the radar image we request each time we change position. The best thing would be to create a specific layer for WMS. I'll probably add this to my todo list, but the principle is the same.
  6. PeterBelow

    Minimizing Forms

    In all newer Delphi versions ( I think this was implemented after Delphi 7) all forms use the Application.Mainform (the first form created in the application's autocreate list) as the window owner on the API level. If that owner window is minimized Windows automatically hides all the owned forms and it also makes sure the owned forms always are displayed above the owner form in the Z order. You can change this behaviour for your secondary forms by overriding the CreateParams method. procedure TFormX.CreateParams( Var params: TCreateParams ); begin inherited CreateParams( params ); // The following disconnects the form from the main form in Z order params.WndParent := GetDesktopwindow; // The following gives the form its own taskbar button params.ExStyle := params.ExStyle or WS_EX_APPWINDOW; end; The side effect is that the main form can now display on top of the secondary form and hide it. For popup forms that can be a problem. This modification also effectively disables the PopupParent of a form, since that is used in the inherited CreateParams to set the WndParent.
  7. In Delphi 11.2, you can change the ComboBox dropdown width using: .DropDownWidth := width, but it is also in the Object Inspector window. And, .AutoDropDownWidth is a boolean, and also in the Object Inspector window. If true, then the width of the cbx will be whatever is the largest text inside the dropdown. When set to false (which is its default), the standard default width is used.
  8. Alexander Sviridenkov

    Unit dependency viwer

    Thank you. Just uploaded 1.0.0.29 - fixed black ellipses and reverted layout to initial settings.
  9. In Delphi 11.2 (maybe also in earlier versions), I have noticed that there now is the property "AutoDropDownWidth" on "TComboBox" to do this.
×