Hi everybody,

As I updated Lazarus this morning, I've seen that FPPkg is not compiling 
anymore. Unless the package maintener is working on this, I've made a patch, 
attached to that mail, to correct that.

I have a more personal concern as well : I would like to colorise some lines 
of a TListView in repport mode depending on some variables where I could 
change TextColor and BackgroundColor. Some of those colors would depend on 
user action so I need to be able to change colors of an item without reloading 
the list.

Do you have an idea on how to do that or even better an exemple of such thing 
? Idealy I need that to work both with GTK and Qt as the application will have 
a runner that will detect the desktop environement and launch GTK or Qt 
version depending on it. I don't need that to work on Windows as the 
application makes sense on Unix systems only.

Thanks for all ;)
-- 
Geoffray « Fatalerrors » Levasseur-Brandin
        <[email protected]>
        <[email protected]>
        http://www.geoffray-levasseur.org/
        http://0linux.org/
GNU/PG public key : A25E944254C62E34A8E58DCF688A5F74289C1897
Errare humanum est sed perseverare diabolicum aut cretinum.
Index: components/fppkg/src/fppkg_mainfrm.pas
===================================================================
--- components/fppkg/src/fppkg_mainfrm.pas	(revision 43301)
+++ components/fppkg/src/fppkg_mainfrm.pas	(working copy)
@@ -158,15 +158,15 @@
     exit;
   Prefix:='';
   case Level of
-    vlWarning :
+    llWarning :
       Prefix:=SWarning;
-    vlError :
+    llError :
       Prefix:=SError;
-{    vlInfo :
+{    llInfo :
       Prefix:='I: ';
-    vlCommands :
+    llCommands :
       Prefix:='C: ';
-    vlDebug :
+    llDebug :
       Prefix:='D: '; }
   end;
 
@@ -574,7 +574,7 @@
   CompilerOptions.UpdateLocalRepositoryOption;
   if FileExists(S) then
   begin
-    pkgglobals.Log(vlDebug, SLogLoadingCompilerConfig, [S]);
+    pkgglobals.Log(llDebug, SLogLoadingCompilerConfig, [S]);
     CompilerOptions.LoadCompilerFromFile(S);
   end
   else
@@ -582,7 +582,7 @@
     // Generate a default configuration if it doesn't exists
     if GlobalOptions.CompilerConfig = 'default' then
     begin
-      pkgglobals.Log(vlDebug, SLogGeneratingCompilerConfig, [S]);
+      pkgglobals.Log(llDebug, SLogGeneratingCompilerConfig, [S]);
       CompilerOptions.InitCompilerDefaults;
       CompilerOptions.SaveCompilerToFile(S);
       if CompilerOptions.SaveInifileChanges then
@@ -592,13 +592,13 @@
       Error(SErrMissingCompilerConfig, [S]);
   end;
   // Log compiler configuration
-  CompilerOptions.LogValues(vlDebug, '');
+  CompilerOptions.LogValues(llDebug, '');
   // Load FPMake compiler config, this is normally the same config as above
   S := GlobalOptions.CompilerConfigDir + GlobalOptions.FPMakeCompilerConfig;
   FPMakeCompilerOptions.UpdateLocalRepositoryOption;
   if FileExists(S) then
   begin
-    pkgglobals.Log(vlDebug, SLogLoadingFPMakeCompilerConfig, [S]);
+    pkgglobals.Log(llDebug, SLogLoadingFPMakeCompilerConfig, [S]);
     FPMakeCompilerOptions.LoadCompilerFromFile(S);
     if FPMakeCompilerOptions.SaveInifileChanges then
       FPMakeCompilerOptions.SaveCompilerToFile(S);
@@ -606,7 +606,7 @@
   else
     Error(SErrMissingCompilerConfig, [S]);
   // Log compiler configuration
-  FPMakeCompilerOptions.LogValues(vlDebug, 'fpmake-building ');
+  FPMakeCompilerOptions.LogValues(llDebug, 'fpmake-building ');
 end;
 
 procedure TFppkgForm.DoRun(cfg: TFppkgConfigOptions; ParaAction: string;
@@ -660,7 +660,7 @@
         laz_pkghandler.Laz_ExecuteAction('', 'laz_update');
       except
         on E: Exception do
-          pkgglobals.Log(vlWarning, E.Message);
+          pkgglobals.Log(llWarning, E.Message);
       end;
     end;
     LoadLocalAvailableRepository;
@@ -677,7 +677,7 @@
       (ParaAction = 'laz_compile') or (ParaAction = 'laz_build') or
       (ParaAction = 'laz_install') or (ParaAction = 'laz_archive')) then
     begin
-      pkgglobals.Log(vlDebug, SLogCheckBrokenDependenvies);
+      pkgglobals.Log(llDebug, SLogCheckBrokenDependenvies);
       SL := TStringList.Create;
       if FindBrokenPackages(SL) then
         Error(SErrBrokenPackagesFound);
@@ -703,7 +703,7 @@
         end
         else
         begin
-          pkgglobals.Log(vlDebug, SLogCommandLineAction,['[' + ParaPackages[i] + ']', ParaAction]);
+          pkgglobals.Log(llDebug, SLogCommandLineAction,['[' + ParaPackages[i] + ']', ParaAction]);
           laz_pkghandler.Laz_ExecuteAction(ParaPackages[i], ParaAction);
         end;
       end;
Index: components/fppkg/src/fppkg_optionsfrm.pas
===================================================================
--- components/fppkg/src/fppkg_optionsfrm.pas	(revision 43301)
+++ components/fppkg/src/fppkg_optionsfrm.pas	(working copy)
@@ -279,12 +279,12 @@
   //setup verbosity
   with VerbosityCheckGroup do
   begin
-    Checked[Items.IndexOf('Error')] := vlError in LazPkgOptions.Verbosity;
-    Checked[Items.IndexOf('Warning')] := vlWarning in LazPkgOptions.Verbosity;
-    Checked[Items.IndexOf('Info')] := vlInfo in LazPkgOptions.Verbosity;
-    Checked[Items.IndexOf('Commands')] := vlCommands in LazPkgOptions.Verbosity;
-    Checked[Items.IndexOf('Debug')] := vlDebug in LazPkgOptions.Verbosity;
-    Checked[Items.IndexOf('Progress')] := vlProgres in LazPkgOptions.Verbosity;
+    Checked[Items.IndexOf('Error')] := llError in LazPkgOptions.Verbosity;
+    Checked[Items.IndexOf('Warning')] := llWarning in LazPkgOptions.Verbosity;
+    Checked[Items.IndexOf('Info')] := llInfo in LazPkgOptions.Verbosity;
+    Checked[Items.IndexOf('Commands')] := llCommands in LazPkgOptions.Verbosity;
+    Checked[Items.IndexOf('Debug')] := llDebug in LazPkgOptions.Verbosity;
+    Checked[Items.IndexOf('Progress')] := llProgres in LazPkgOptions.Verbosity;
   end;
 end;
 
@@ -297,17 +297,17 @@
   with VerbosityCheckGroup do
   begin
     if Checked[Items.IndexOf('Error')] then
-      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [vlError];
+      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [llError];
     if Checked[Items.IndexOf('Warning')] then
-      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [vlWarning];
+      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [llWarning];
     if Checked[Items.IndexOf('Info')] then
-      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [vlInfo];
+      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [llInfo];
     if Checked[Items.IndexOf('Commands')] then
-      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [vlCommands];
+      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [llCommands];
     if Checked[Items.IndexOf('Debug')] then
-      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [vlDebug];
+      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [llDebug];
     if Checked[Items.IndexOf('Progress')] then
-      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [vlProgres];
+      LazPkgOptions.Verbosity := LazPkgOptions.Verbosity + [llProgres];
   end;
 
   Close;
Index: components/fppkg/src/laz_pkghandler.pas
===================================================================
--- components/fppkg/src/laz_pkghandler.pas	(revision 43301)
+++ components/fppkg/src/laz_pkghandler.pas	(working copy)
@@ -19,9 +19,9 @@
   pkghandlerclass:=GetPkgHandler(AAction);
   With pkghandlerclass.Create(nil,APackageName) do
     try
-      Log(vlDebug,SLogRunAction+' start',[AAction]);
+      Log(llDebug,SLogRunAction+' start',[AAction]);
       Execute;
-      Log(vlDebug,SLogRunAction+' end',[AAction]);
+      Log(llDebug,SLogRunAction+' end',[AAction]);
     finally
       Free;
     end;
Index: components/fppkg/src/laz_pkgrepos.pas
===================================================================
--- components/fppkg/src/laz_pkgrepos.pas	(revision 43301)
+++ components/fppkg/src/laz_pkgrepos.pas	(working copy)
@@ -87,7 +87,7 @@
 implementation
 
 uses
-  pkgglobals,
+  pkgglobals, fpmkunit,
   pkgrepos;
 
 function Laz_PackageInstalledVersionStr(const AName:String;const ShowUsed: boolean = false;const Local: boolean = false):string;

Attachment: signature.asc
Description: This is a digitally signed message part.

--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to