From d64d86771050cc6f43ff65f8a4200d0b77629c8d Mon Sep 17 00:00:00 2001 From: larsbrubaker Date: Sun, 22 Feb 2015 10:01:06 -0800 Subject: [PATCH] Made the print timing info still allow the the terminal window to filter correctyl. --- PrinterCommunication/PrinterConnectionAndCommunication.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/PrinterCommunication/PrinterConnectionAndCommunication.cs b/PrinterCommunication/PrinterConnectionAndCommunication.cs index 1c46fa936..1d39cbc93 100644 --- a/PrinterCommunication/PrinterConnectionAndCommunication.cs +++ b/PrinterCommunication/PrinterConnectionAndCommunication.cs @@ -1944,11 +1944,12 @@ namespace MatterHackers.MatterControl.PrinterCommunication StringEventArgs currentEvent = new StringEventArgs(lineToWrite); if (PrinterIsPrinting) { - CommunicationUnconditionalFromPrinter.CallEvents(this, new StringEventArgs("[{0}] {1}".FormatWith(timeSinceStartedPrint.ElapsedMilliseconds, lineToWrite))); + string lineWidthoutCR = lineToWrite.Substring(0, lineToWrite.Length - 2); + CommunicationUnconditionalToPrinter.CallEvents(this, new StringEventArgs("{0} [{1}]\n".FormatWith(lineWidthoutCR, timeSinceStartedPrint.ElapsedMilliseconds))); } else { - CommunicationUnconditionalFromPrinter.CallEvents(this, currentEvent); + CommunicationUnconditionalToPrinter.CallEvents(this, currentEvent); } if (lineWithoutChecksum != null) @@ -2609,7 +2610,7 @@ namespace MatterHackers.MatterControl.PrinterCommunication StringEventArgs currentEvent = new StringEventArgs(lastLineRead); if (PrinterIsPrinting) { - CommunicationUnconditionalFromPrinter.CallEvents(this, new StringEventArgs("[{0}] {1}".FormatWith(timeSinceStartedPrint.ElapsedMilliseconds, lastLineRead))); + CommunicationUnconditionalFromPrinter.CallEvents(this, new StringEventArgs("{0} [{1}]\n".FormatWith(lastLineRead, timeSinceStartedPrint.ElapsedMilliseconds))); } else {