erizet / nlogviewer Goto Github PK
View Code? Open in Web Editor NEWNlogViewer is a simple WPF-control to show NLog-logs.
License: MIT License
NlogViewer is a simple WPF-control to show NLog-logs.
License: MIT License
Is there a way to override the BackgroundMouseOver and ForegroundMouseOver color scheme?
Making a simple WPF application, following the readme, and logging text yields an application that looks like this: https://gyazo.com/e7c630a66fe319a8995b58e9f451c5aa
Hovering over areas in the view had a tooltip display for the message, so it seemed like logging worked, but rendering was broke.
After digging through the code and trying to figure out why things weren't working out of the box, I realized the width properties have no default values, so things appear broken when they're really not.
After manually setting widths, everything worked as expected: https://gyazo.com/0ca572ba5ca9252e001695cde0862131
Please add default width values, or update the readme example to mention this, to save others from similar issues when trying NlogViewer.
For example:
<nlogViewer:NlogViewer x:Name="logCtrl" ExceptionWidth = "100" MessageWidth="100" LevelWidth="100" TimeWidth="100" LoggerNameWidth="100"/>
Hello,
is this open source project? There is no license specified.
Thank you,
Pavel
Hi. Very nice control, thanks!
One comment: it was not obvious (to me) at first how to get scroll bars. Some googling revealed it is pretty simple ... simply set the height; e.g. <NLogViewer Height="xxx" ...>. Would be nice to have that in the doc or example.
Now that I have the scrollbar, it would be nice to have the listview scroll to the end. It seems possible but would need modification to the control, I think. I would advocate for scroll-to-end to be the default.
It's more a new feature request, I'd like to allow the user to stop the stream of data (e.g. the user already find the line was looking for) .
The change could be in NlogViewer.xaml.cs
`
private bool _isPausing = false;
[Description("Pause the receiving of data"), Category("Data")]
[TypeConverter(typeof(BooleanConverter))]
public bool Pause
{
get { return _isPausing; }
set { _isPausing = value; }
}
`
and in method LogReceived the _isPausing can be checked.
If you'd like I can push a branch with the changes.
Is there a way to change the columns that are displayed? I was wanting to add the timestamp.
Right now the terms on which you share your code are not clear.
This should have been a request on SO but i do not have enough reputation to ask! Apologies if its already possible. Could you point me in the right direction if it is? My email is [email protected]
Could you share how to setup nlog extension from code?
As NLog Update to Nlog 5.0, How to use Fluent Configuration API to binding NlogViewer ?
like this way:
NLog.LogManager.Setup().LoadConfiguration(builder => {
builder.ForLogger().FilterMinLevel(LogLevel.Info).WriteToConsole();
builder.ForLogger().FilterMinLevel(LogLevel.Debug).WriteToFile(fileName: "file.txt");
});
Thank you for this library. Ive been pulling my hair to add WPF richtextbox support without full success. Very handy.
Could you add silverlight support to this library?
I dont know where to ask. I dont have your website or your email. Pardon me for asking it here.
Thanks.
Nevermind. Fixed it.
the row in README.MD:
<nlog:NlogViewer x:Name="logCtrl" />
should be
<nlog:NlogViewer x:Name="ctrl" />
for the example to work
Hi, great control by the way! I'm new to it, but through the examples I cannot relate targeting two different NlogViewers. I guess it would be something like:
<extensions>
<add assembly="NlogViewer" />
</extensions>
<targets>
<target xsi:type="NlogViewer" name="logCtrl1" />
<target xsi:type="NlogViewer" name="logCtrl2" />
</targets>
<rules>
<logger name="*" minlevel="Debug" writeTo="logCtrl1" />
<logger name="*" minlevel="Trace" writeTo="logCtrl2" />
</rules>
but I don't know how to configure the WPF control itself to be the target of "logCtrl1" and "logCtrl2"
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.