1 /* 2 SPDX-FileCopyrightText: 2007 Nicolas Ternisien <nicolas.ternisien@gmail.com> 3 4 SPDX-License-Identifier: GPL-2.0-or-later 5 */ 6 7 #include "sambaItemBuilder.h" 8 createFormattedText(LogLine * line) const9QString SambaItemBuilder::createFormattedText(LogLine *line) const 10 { 11 QString result; 12 13 QListIterator<QString> it(line->logItems()); 14 15 result.append(QLatin1String("<table>")); 16 17 result.append(labelMessageFormat(i18n("Date:"), formatDate(line->time()))); 18 result.append(labelMessageFormat(i18n("Level:"), line->logLevel()->name())); 19 result.append(labelMessageFormat(i18n("Source File:"), it.next())); 20 result.append(labelMessageFormat(i18n("Function:"), it.next())); 21 result.append(labelMessageFormat(i18n("Line:"), it.next())); 22 23 result.append(QLatin1String("</table>")); 24 25 return result; 26 } 27