diff options
author | Sean Dague | 2008-02-06 20:59:31 +0000 |
---|---|---|
committer | Sean Dague | 2008-02-06 20:59:31 +0000 |
commit | caa255bcdf6722062c660ed26844a68c5987ffd8 (patch) | |
tree | beaac458f081aef03e87ff65691ac4e310ff1348 /OpenSim/Framework/Console | |
parent | * Allow terrain load-tile for RAW files (diff) | |
download | opensim-SC-caa255bcdf6722062c660ed26844a68c5987ffd8.zip opensim-SC-caa255bcdf6722062c660ed26844a68c5987ffd8.tar.gz opensim-SC-caa255bcdf6722062c660ed26844a68c5987ffd8.tar.bz2 opensim-SC-caa255bcdf6722062c660ed26844a68c5987ffd8.tar.xz |
make a couple more changes to get us back very close to old color scheme
Diffstat (limited to 'OpenSim/Framework/Console')
-rw-r--r-- | OpenSim/Framework/Console/OpenSimAppender.cs | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/OpenSim/Framework/Console/OpenSimAppender.cs b/OpenSim/Framework/Console/OpenSimAppender.cs index fb3c7c2..6b1ba39 100644 --- a/OpenSim/Framework/Console/OpenSimAppender.cs +++ b/OpenSim/Framework/Console/OpenSimAppender.cs | |||
@@ -15,7 +15,7 @@ namespace OpenSim.Framework.Console | |||
15 | override protected void Append(LoggingEvent le) | 15 | override protected void Append(LoggingEvent le) |
16 | { | 16 | { |
17 | string loggingMessage = RenderLoggingEvent(le); | 17 | string loggingMessage = RenderLoggingEvent(le); |
18 | string regex = @"^(?<Front>.*)\[(?<Category>\w+)\](?<End>.*)"; | 18 | string regex = @"^(?<Front>.*?)\[(?<Category>\w+)\]:?(?<End>.*)"; |
19 | 19 | ||
20 | Regex RE = new Regex(regex, RegexOptions.Multiline); | 20 | Regex RE = new Regex(regex, RegexOptions.Multiline); |
21 | MatchCollection matches = RE.Matches(loggingMessage); | 21 | MatchCollection matches = RE.Matches(loggingMessage); |
@@ -26,8 +26,21 @@ namespace OpenSim.Framework.Console | |||
26 | System.Console.Write("["); | 26 | System.Console.Write("["); |
27 | 27 | ||
28 | WriteColorText(DeriveColor(matches[0].Groups["Category"].Value), matches[0].Groups["Category"].Value); | 28 | WriteColorText(DeriveColor(matches[0].Groups["Category"].Value), matches[0].Groups["Category"].Value); |
29 | System.Console.Write("]"); | 29 | System.Console.Write("]:"); |
30 | System.Console.WriteLine(matches[0].Groups["End"].Value); | 30 | |
31 | if (le.Level == Level.Error) | ||
32 | { | ||
33 | WriteColorText(ConsoleColor.Red, matches[0].Groups["End"].Value); | ||
34 | } | ||
35 | else if (le.Level == Level.Warn) | ||
36 | { | ||
37 | WriteColorText(ConsoleColor.Yellow, matches[0].Groups["End"].Value); | ||
38 | } | ||
39 | else | ||
40 | { | ||
41 | System.Console.Write(matches[0].Groups["End"].Value); | ||
42 | } | ||
43 | System.Console.WriteLine(); | ||
31 | } | 44 | } |
32 | else | 45 | else |
33 | { | 46 | { |