* * *

Recent Posts

Pages: [1] 2 3 ... 10
1
Third party / TExtRadioGroup with rules, maybe to upgrade
« Last post by matthius on Today at 12:17:30 pm »
Here is TExtRadioGroup, TExtDBRadioGroup, TExtChecksGroup, with rules,

https://bitbucket.org/matthieugiroux/extended/downloads/

There is also virtualdbtreeex for finished rules :
https://bitbucket.org/matthieugiroux/virtualdbtreeex-interface-with-checks-entirely-created-with/downloads/
2
Cocoa / Re: Is Cocoa the future for Lazarus on macOS?
« Last post by GillesH on Today at 10:11:45 am »
Hello,

Just passing by. I use every day Qt on my mac. I do not think the support of Qt by Lazarus is the future of Lazarus because Lazarus greatly reduces qt's capabilities. In addition it is necessary to distribute all necessary qt libraries.

But I can not understand. In interpreting your remarks, I understand that it is currently possible to use an experimental trunk lazarus cocoa ?

The cross compilation is a problem : I tried from Lazarus Carbon to use UniDac by cross-compiling to 64-bit Cocoa: total failure.

I believe that to develop the use of Lazarus under macOS you must facilitate its installation.

It takes a step-by-step tutorial, updated to the new version of Mac: OS 10.12.6, including the installation of an integrated debugger ... even if it's under Carbon 32.

Then you need a step-by-step tutorial to cross-compile the projects to Cocoa 64.

Do not complain if there is no Mac OS Lazarus's user. Installation is very difficult when compared to the Windows or Linux installation.

Then for someone who wants to test Lazarus, it is almost a blow on abandonment before even being able to test it.

I installed Lazarus, managed to integrate gdb and dropped to cross-compilation. Too painful, too time consuming, too complicated ...

Regards. Gilles
3
Android / Re: cannot find system used by FCLLAZ of package FCL
« Last post by Prakash on Today at 09:53:52 am »
Thanks for quick reply.

Can we use android third party library with LAMW on windows Or can we use java and pascal mix.

Prakash.
4
IDE/CodeTools / Re: Keeping track of project statistics - timings
« Last post by GetMem on Today at 08:49:22 am »
Hi all,

Thanks for the feedback and sorry for the late reply, I was out in the wild with no internet connection.

@taazz
Quote
1) object inspector is grouped in other, it should be grouped in designer. well grain of salt and all that.
Quote
2) main menu is grouped in other as well it should not change the group use the last active group.
Quote
3) It has a small after effect that if your other application is not maximized every time the mouse passes over the editor it registers as editing time although lazarus is not focused.
Fixed.


@ertank
Quote
1- I suggest mouse move should not be considered as active. Just clicks. When I click a form or Edit window status can be active.
Fixed.

Quote
2- When Idle triggers, would be nice to reduce (last timing - Idle delay timing) in order to have correct calculation as 10 seconds will pile up and may even make hours overall.
I changed to 2 seconds, it will be configurable in the future.



@Thaddy
Quote
I mean even worse... logging on the network.... In a team that is functional. I even introduced it many times... Just for code, not for web/email/private things.
Ok. Linking two or more Lazarus IDE for a team project make sense, but then you need a server and the implementation would require a lot of work. I'm not against it, but I'm not gonna implement it, at least not in the near future.

PS: As time permits, I will continue the development and report back. Thanks again for the feedback.
5
General / Re: listview move item up or down
« Last post by Ericktux on Today at 07:15:27 am »
Thanks to all my friends, Works perfect   :D :D
I have created two projects thanks to your help.

project one: (Simple but effective)

Code: Pascal  [Select]
  1. unit Unit1;
  2.  
  3. {$mode objfpc}{$H+}
  4.  
  5. interface
  6.  
  7. uses
  8.   Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ComCtrls,
  9.   Buttons;
  10.  
  11. type
  12.  
  13.   { TForm1 }
  14.  
  15.   TForm1 = class(TForm)
  16.     BitBtn1: TBitBtn;
  17.     BitBtn2: TBitBtn;
  18.     ListView1: TListView;
  19.     procedure BitBtn1Click(Sender: TObject);
  20.     procedure BitBtn2Click(Sender: TObject);
  21.     procedure FormCreate(Sender: TObject);
  22.   private
  23.     { private declarations }
  24.   public
  25.     { public declarations }
  26.   end;
  27.  
  28. var
  29.   Form1: TForm1;
  30.  
  31. implementation
  32.  
  33. {$R *.lfm}
  34.  
  35. { TForm1 }
  36.  
  37. procedure TForm1.FormCreate(Sender: TObject);
  38. var
  39.   enumerando: integer;
  40. begin
  41.     with Form1.ListView1.Items.Add do
  42.   begin
  43.   Caption:= '';
  44.   SubItems.Add('erick');
  45.   SubItems.Add('caceres');
  46.   SubItems.Add('peña');
  47.   end;
  48.  
  49.     with Form1.ListView1.Items.Add do
  50.   begin
  51.   Caption:= '';
  52.   SubItems.Add('juan');
  53.   SubItems.Add('galvez');
  54.   SubItems.Add('soto');
  55.   end;
  56.  
  57.       with Form1.ListView1.Items.Add do
  58.   begin
  59.   Caption:= '';
  60.   SubItems.Add('luis');
  61.   SubItems.Add('flores');
  62.   SubItems.Add('layme');
  63.   end;
  64.  
  65.     with Form1.ListView1.Items.Add do
  66.   begin
  67.   Caption:= '';
  68.   SubItems.Add('leo');
  69.   SubItems.Add('allca');
  70.   SubItems.Add('gonzales');
  71.   end;
  72.  
  73.        with Form1.ListView1.Items.Add do
  74.   begin
  75.   Caption:= '';
  76.   SubItems.Add('gustavo');
  77.   SubItems.Add('mares');
  78.   SubItems.Add('tacna');
  79.   end;
  80.  
  81.     with Form1.ListView1.Items.Add do
  82.   begin
  83.   Caption:= '';
  84.   SubItems.Add('fred');
  85.   SubItems.Add('tonasca');
  86.   SubItems.Add('sierra');
  87.   end;
  88.  
  89.      with Form1.ListView1.Items.Add do
  90.   begin
  91.   Caption:= '';
  92.   SubItems.Add('bernardo');
  93.   SubItems.Add('luna');
  94.   SubItems.Add('roca');
  95.   end;
  96.  
  97.         begin // volviendo a enumerar después de borrar
  98.         for enumerando := 0 to ListView1.Items.Count-1 do
  99.         ListView1.Items[enumerando].Caption := IntToStr(enumerando+1);
  100.         end;
  101. end;
  102.  
  103. procedure TForm1.BitBtn1Click(Sender: TObject);  // MOVE ITEM UP
  104. var
  105.   Sel: TListItem;
  106.   enumerando: integer;
  107. begin
  108.   ListView1.MultiSelect:=false;
  109.   Sel := ListView1.Selected;
  110.   if Assigned(Sel) then
  111.     if Sel.Index - 1 >= 0 then
  112.       ListView1.Items.Exchange(Sel.Index, Sel.Index - 1);
  113.  
  114.   ListView1.SetFocus;
  115.   ListView1.MultiSelect:=true;
  116.  
  117.         begin // volviendo a enumerar después de borrar
  118.         for enumerando := 0 to ListView1.Items.Count-1 do
  119.         ListView1.Items[enumerando].Caption := IntToStr(enumerando+1);
  120.         end;
  121. end;
  122.  
  123. procedure TForm1.BitBtn2Click(Sender: TObject);  // MOVE ITEM DOWN
  124. var
  125.   Sel: TListItem;
  126.   enumerando: integer;
  127. begin
  128.   ListView1.MultiSelect:=false;
  129.   Sel := ListView1.Selected;
  130.   if Assigned(Sel) then
  131.     if Sel.Index + 1 < ListView1.Items.Count then
  132.       ListView1.Items.Exchange(Sel.Index, Sel.Index + 1);
  133.  
  134.     ListView1.SetFocus;
  135.   ListView1.MultiSelect:=true;
  136.  
  137.         begin // volviendo a enumerar después de borrar
  138.         for enumerando := 0 to ListView1.Items.Count-1 do
  139.         ListView1.Items[enumerando].Caption := IntToStr(enumerando+1);
  140.         end;
  141. end;
  142. end.


Project two: (Excellent with advanced features)

Code: Pascal  [Select]
  1. unit Unit1;
  2.  
  3. {$mode objfpc}{$H+}
  4.  
  5. interface
  6.  
  7. uses
  8.   Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ComCtrls,
  9.   Buttons, uListViewUtils;
  10.  
  11. type
  12.  
  13.   { TForm1 }
  14.  
  15.   TForm1 = class(TForm)
  16.     BitBtn1: TBitBtn;
  17.     BitBtn2: TBitBtn;
  18.     BitBtn3: TBitBtn;
  19.     BitBtn4: TBitBtn;
  20.     BitBtn5: TBitBtn;
  21.     BitBtn6: TBitBtn;
  22.     BitBtn7: TBitBtn;
  23.     ListView1: TListView;
  24.     procedure BitBtn1Click(Sender: TObject);
  25.     procedure BitBtn2Click(Sender: TObject);
  26.     procedure BitBtn3Click(Sender: TObject);
  27.     procedure BitBtn4Click(Sender: TObject);
  28.     procedure BitBtn5Click(Sender: TObject);
  29.     procedure BitBtn6Click(Sender: TObject);
  30.     procedure BitBtn7Click(Sender: TObject);
  31.     procedure FormCreate(Sender: TObject);
  32.   private
  33.     { private declarations }
  34.   public
  35.     { public declarations }
  36.     procedure number_all;
  37.   end;
  38.  
  39. var
  40.   Form1: TForm1;
  41.   enumerando: integer;
  42.  
  43. implementation
  44.  
  45. {$R *.lfm}
  46.  
  47. { TForm1 }
  48.  
  49. procedure tform1.number_all;
  50. begin
  51.     // volviendo a enumerar después de borrar
  52.     for enumerando := 0 to ListView1.Items.Count-1 do
  53.     ListView1.Items[enumerando].Caption := IntToStr(enumerando+1);
  54. end;
  55.  
  56. procedure TForm1.FormCreate(Sender: TObject);
  57. var
  58.   enumerando: integer;
  59. begin
  60.     with Form1.ListView1.Items.Add do
  61.   begin
  62.   Caption:= '';
  63.   SubItems.Add('erick');
  64.   SubItems.Add('caceres');
  65.   SubItems.Add('peña');
  66.   end;
  67.  
  68.     with Form1.ListView1.Items.Add do
  69.   begin
  70.   Caption:= '';
  71.   SubItems.Add('juan');
  72.   SubItems.Add('galvez');
  73.   SubItems.Add('soto');
  74.   end;
  75.  
  76.       with Form1.ListView1.Items.Add do
  77.   begin
  78.   Caption:= '';
  79.   SubItems.Add('luis');
  80.   SubItems.Add('flores');
  81.   SubItems.Add('layme');
  82.   end;
  83.  
  84.     with Form1.ListView1.Items.Add do
  85.   begin
  86.   Caption:= '';
  87.   SubItems.Add('leo');
  88.   SubItems.Add('allca');
  89.   SubItems.Add('gonzales');
  90.   end;
  91.  
  92.        with Form1.ListView1.Items.Add do
  93.   begin
  94.   Caption:= '';
  95.   SubItems.Add('gustavo');
  96.   SubItems.Add('mares');
  97.   SubItems.Add('tacna');
  98.   end;
  99.  
  100.     with Form1.ListView1.Items.Add do
  101.   begin
  102.   Caption:= '';
  103.   SubItems.Add('fred');
  104.   SubItems.Add('tonasca');
  105.   SubItems.Add('sierra');
  106.   end;
  107.  
  108.      with Form1.ListView1.Items.Add do
  109.   begin
  110.   Caption:= '';
  111.   SubItems.Add('bernardo');
  112.   SubItems.Add('luna');
  113.   SubItems.Add('roca');
  114.   end;
  115.  
  116.         begin // volviendo a enumerar después de borrar
  117.         for enumerando := 0 to ListView1.Items.Count-1 do
  118.         ListView1.Items[enumerando].Caption := IntToStr(enumerando+1);
  119.         end;
  120.  
  121.   ListView1.OnDragDrop := @ListViewUtils.DragDrop;
  122.   ListView1.OnDragOver := @ListViewUtils.DragOver;
  123.   ListView1.OnMouseDown := @ListViewUtils.MouseDown;
  124.   ListView1.OnMouseMove := @ListViewUtils.MouseMove;
  125.   {$ifdef LINUX}
  126.     ListView1.DragMode := dmManual;
  127.   {$endif};
  128. end;
  129.  
  130. procedure TForm1.BitBtn1Click(Sender: TObject);  // MOVE ITEM UP
  131. begin
  132.      ListViewUtils.MoveItemsUp(ListView1);
  133.      number_all;
  134. end;
  135.  
  136. procedure TForm1.BitBtn2Click(Sender: TObject);  // MOVE ITEM DOWN
  137. begin
  138.       ListViewUtils.MoveItemsDown(ListView1);
  139.       number_all;
  140. end;
  141.  
  142. procedure TForm1.BitBtn3Click(Sender: TObject);
  143. begin
  144.   ListViewUtils.MoveItemsTop(ListView1);
  145.   number_all;
  146. end;
  147.  
  148. procedure TForm1.BitBtn4Click(Sender: TObject);
  149. begin
  150.   ListViewUtils.MoveItemsBottom(ListView1);
  151.   number_all;
  152. end;
  153.  
  154. procedure TForm1.BitBtn5Click(Sender: TObject);
  155. begin
  156.   ListViewUtils.DeleteItems(ListView1);
  157.   number_all;
  158. end;
  159.  
  160. procedure TForm1.BitBtn6Click(Sender: TObject);
  161. begin
  162.   ListViewUtils.ToggleSelectAll(ListView1);
  163. end;
  164.  
  165. procedure TForm1.BitBtn7Click(Sender: TObject);
  166. begin
  167.     ListViewUtils.ToggleCheckItems(ListView1);
  168. end;
  169.  
  170. end.



PD: Attach images and projects
Thanks again friends  :) :)
6
Mac OS X / Data Validation Problem - SetFocus
« Last post by ranlaborde on Today at 05:03:12 am »
I have isolated the problem I am having as explained in the previous post.  The behaviour of SetFocus appears different under Mac than it is under Windows.  If I SetFocus a TextBox to itself it highlights then next control in tab order and then highlights the Textbox pointed to through the SetFocus.  This seems that this problem would be a fairly general issue that has a solution (I just don't know it!). 

Also... Why is the behaviour different when the OK button in the error message is clicked (one control highlighted) vs Enter (two controls highlighted?)   
7
Beginners / Re: Overwrite curent line
« Last post by molly on Today at 03:46:01 am »
Sorry for the delay (i had to do something else first).

This is my take at things:
Code: Pascal  [Select]
  1. procedure Update;
  2. const
  3.   {$IFDEF MOLLYS_COMPUTER}
  4.   BasePath = 'H:\Lazarus-forums\37580\';
  5.   {$ELSE}
  6.   BasePath = 'C:\Users\';
  7.   {$ENDIF}
  8.   GatherFile = BasePath + 'Public\print\checkall\all.csv';
  9. var
  10.   // Directory where Motherboard information is stored
  11.   MoBoDir       : String = BasePath + 'Public\print\check';
  12.   MoBoFiles     : TStringList;  // List containing found Motherboard Filenames
  13.   MoBoFileIndex : integer;      // Index to iterate MoBoFiles list
  14.  
  15.   MoBoContents  : TStringList;  // List with contents of a Motherboard file
  16.   FieldIndex    : integer;      // index to iterate MoBoContents list
  17.   MoBoIdentifier: string;       // Motherboard identifier
  18.   MoBoValues    : String;       // Motherboard additional values
  19.  
  20.   GatherContents: TStringList;  // List that contaisn combined contents of Motherboards
  21. begin
  22.   MoBoFiles := TStringList.Create;
  23.  
  24.   // Find all Motherboard filenames
  25.   FindAllFiles(MoBoFiles, MoBoDir, '*', false);
  26.  
  27.   // If there are any motherboard files then we need to continue
  28.   if (MoBoFiles.Count > 0) then
  29.   begin
  30.     GatherContents := TStringList.Create;
  31.     GatherContents.NameValueSeparator := #9;  // Separated by tab
  32.  
  33.     // Load pre-existing combined file in case it exists
  34.     if FileExists(GatherFile)
  35.       then GatherContents.LoadFromFile(GatherFile);
  36.  
  37.     // process each MotherBoard file
  38.     for MoBoFileIndex := 0 to Pred(MoBoFiles.Count) do
  39.     begin
  40.       // Load the contents of the Motherboard file
  41.       MoBoContents := TStringList.Create;
  42.       MoBoContents.LoadFromFile(MoBoFiles[MoBoFileIndex]);
  43.  
  44.       //
  45.       // process contents of Motherboard file
  46.       //
  47.       MoBoValues := '';
  48.       // Process each and every line in a motherboard file
  49.       for FieldIndex := 0 to Pred(MoBoContents.Count) do
  50.       begin
  51.         // The first line is always the motherboad identifier
  52.         if FieldIndex = 0 then MoBoIdentifier := MoBoContents[FieldIndex]
  53.         else
  54.         // the following lines contain additional motherboard information
  55.         // copy them one-by-one into string MoBoVlaues, separated by a tab
  56.         // character
  57.         begin
  58.           MoBoValues := MoBoValues + MoBoContents[FieldIndex];
  59.           if FieldIndex < Pred(MoBoContents.Count)
  60.           then MoBoValues := MoBoValues + #9;
  61.         end;
  62.       end;
  63.  
  64.       // Add/Replace motherboard information in the gathered combined list
  65.       GatherContents.Values[MoBoIdentifier] := MoBoValues;
  66.  
  67.       // Free the Motherboard contents list from memory
  68.       MoBoContents.Free;
  69.     end;
  70.  
  71.     // Save the updated gathered information back to file
  72.     GatherContents.SaveToFile(GatherFile);
  73.    
  74.     // Free the list with gathered informationt
  75.     GatherContents.Free;
  76.   end;
  77.  
  78.   // Free the list with motherboard filenames
  79.   MoBoFiles.Free;
  80. end;
  81.  
8
Mac OS X / Re: Trying to Install 3.0.2 - No Xcode Message
« Last post by Phil on Today at 02:40:56 am »
Installed 8.3 command line tools and still no gdb.   Upon further reading on web it appears gdb is not included with Apple CLT anymore and the gdb program is not compatible with Mac OS Sierra due to security feature changes.  Can I proceed without gdb?

Apple moved away from gcc/gdb years ago and now includes llvm/lldb with Xcode. You have several options:

- Run without debugger. On 1.8 you can Run | Run without Debugging.

- Debug with lldb at command line.

https://developer.apple.com/library/content/documentation/IDEs/Conceptual/gdb_to_lldb_transition_guide/document/lldb-terminal-workflow-tutorial.html#//apple_ref/doc/uid/TP40012917-CH4-SW1

- Export Laz project to Xcode and debug it there.

https://macpgmr.github.io/ObjP/ProjectXC.html

- Maybe, just maybe you can get gdb running, but the reports are mixed. I don't even bother trying.

https://www.freepascal.org/~michael/articles/lazonmac/lazonmac.pdf

9
Mac OS X / Re: Trying to Install 3.0.2 - No Xcode Message
« Last post by Dan3468298 on Today at 02:32:16 am »
Installed 8.3 command line tools and still no gdb.   Upon further reading on web it appears gdb is not included with Apple CLT anymore and the gdb program is not compatible with Mac OS Sierra due to security feature changes.  Can I proceed without gdb?
10
Beginners / Re: Overwrite curent line
« Last post by samoraj on Today at 01:56:04 am »
No problem to be txt
Pages: [1] 2 3 ... 10

Recent

Get Lazarus at SourceForge.net. Fast, secure and Free Open Source software downloads Open Hub project report for Lazarus