Bug 110856 - JJ: Add composer placeholder like %MSID for Message-ID without angle brackets (RFC1738)
Summary: JJ: Add composer placeholder like %MSID for Message-ID without angle brackets...
Status: RESOLVED FIXED
Alias: None
Product: knode
Classification: Miscellaneous
Component: general (show other bugs)
Version: unspecified
Platform: openSUSE Linux
: NOR wishlist
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-16 00:43 UTC by Tristan Miller
Modified: 2009-07-22 14:11 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments
Patch against trunk (1.73 KB, patch)
2006-03-03 15:21 UTC, Grzegorz Oledzki
Details
patch against 3.5 (1.86 KB, patch)
2006-03-03 15:26 UTC, Grzegorz Oledzki
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tristan Miller 2005-08-16 00:43:31 UTC
Version:            (using KDE KDE 3.4.2)
Installed from:    SuSE RPMs

In Settings->Configure KNode->Posting News->Composer->Reply, there is a list of supported placeholders.  One of these is %MSID, which inserts the Message-ID, including the surrounding angle brackets <…>.

Please also include a placeholder which inserts the Message-ID without the angle brackets.  This allows us to construct RFC1738-compliant URLs, such as in the following introduction phrase:

In article <news:%MSIDX>, %NAME wrote:
Comment 1 Grzegorz Oledzki 2006-03-03 15:21:00 UTC
Created attachment 14936 [details]
Patch against trunk

I added the "%MS-IDX" placeholder as proposed.
Comment 2 Grzegorz Oledzki 2006-03-03 15:22:17 UTC
"%MSIDX" (the previous one was a type, but only in the comment - not in the patch)
Comment 3 Grzegorz Oledzki 2006-03-03 15:26:10 UTC
Created attachment 14937 [details]
patch against 3.5
Comment 4 Grzegorz Oledzki 2006-06-14 10:40:43 UTC
And?
Is something wrong with my code?
Comment 5 Grzegorz Oledzki 2006-10-10 00:58:11 UTC
And?
Comment 6 Volker Krause 2006-11-11 18:13:02 UTC
SVN commit 604131 by vkrause:

forward-port patch for #110856 by Grzegorz Oledzki <grzegon@poczta.onet.pl>

CCBUG: 110856


 M  +3 -3      knarticlefactory.cpp  
 M  +17 -23    postnewscomposerwidget_base.ui  


--- trunk/KDE/kdepim/knode/knarticlefactory.cpp #604130:604131
@@ -222,9 +222,9 @@
   attribution.replace(QRegExp("%NAME"),name);
   attribution.replace(QRegExp("%EMAIL"),QString::fromLatin1(a->from()->email()));
   attribution.replace(QRegExp("%DATE"),KGlobal::locale()->formatDateTime(a->date()->qdt(),false));
-  QString msid=a->messageID()->asUnicodeString();
-  attribution.replace(QRegExp("%MSIDX"),msid.mid(1,msid.length()-2));          // remove the "<" ">" braces
-  attribution.replace(QRegExp("%MSID"),msid);
+  QString msid = a->messageID()->identifier();
+  attribution.replace( QRegExp("%MSIDX"), msid );
+  attribution.replace( QRegExp("%MSID"), QLatin1Char('<') + msid + QLatin1Char('>') );
   attribution.replace(QRegExp("%GROUP"),g->groupname());
   attribution.replace(QRegExp("%L"),"\n");
   attribution+="\n\n";
--- trunk/KDE/kdepim/knode/postnewscomposerwidget_base.ui #604130:604131
@@ -1,15 +1,13 @@
 <ui version="4.0" >
  <author>Volker Krause &lt;volker.krause@rwth-aachen.de></author>
- <comment></comment>
- <exportmacro></exportmacro>
  <class>KNode::PostNewsComposerWidgetBase</class>
- <widget class="KCModule" name="PostNewsComposerWidgetBase" >
+ <widget class="KCModule" native="1" name="KNode::PostNewsComposerWidgetBase" >
   <property name="geometry" >
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>412</width>
-    <height>443</height>
+    <width>573</width>
+    <height>565</height>
    </rect>
   </property>
   <layout class="QVBoxLayout" >
@@ -79,8 +77,11 @@
       <item>
        <widget class="QLabel" name="label2" >
         <property name="text" >
-         <string>&lt;qt>Placeholders: &lt;b>%NAME&lt;/b>=sender's name, &lt;b>%EMAIL&lt;/b>=sender's address,&lt;br>&lt;b>%DATE&lt;/b>=date, &lt;b>%MSID&lt;/b>=message-id, &lt;b>%GROUP&lt;/b>=group name, &lt;b>%L&lt;/b>=line break&lt;/qt></string>
+         <string>&lt;qt>Placeholders: &lt;b>%NAME&lt;/b>=sender's name, &lt;b>%EMAIL&lt;/b>=sender's address,&lt;br>&lt;b>%DATE&lt;/b>=date, &lt;b>%MSID&lt;/b>=message-id, &lt;b>%MSIDX&lt;/b>=message-id without angle brackets, &lt;b>%GROUP&lt;/b>=group name, &lt;b>%L&lt;/b>=line break&lt;/qt></string>
         </property>
+        <property name="wordWrap" >
+         <bool>true</bool>
+        </property>
        </widget>
       </item>
       <item>
@@ -165,33 +166,26 @@
  <pixmapfunction>qPixmapFromMimeSource</pixmapfunction>
  <customwidgets>
   <customwidget>
-   <class>KIntSpinBox</class>
-   <extends></extends>
-   <header>knuminput.h</header>
-   <container>0</container>
-   <pixmap></pixmap>
+   <class>KUrlRequester</class>
+   <extends>QFrame</extends>
+   <header>kurlrequester.h</header>
   </customwidget>
   <customwidget>
    <class>KLineEdit</class>
-   <extends></extends>
+   <extends>QLineEdit</extends>
    <header>klineedit.h</header>
-   <container>0</container>
-   <pixmap></pixmap>
   </customwidget>
   <customwidget>
-   <class>KUrlRequester</class>
-   <extends></extends>
-   <header>kurlrequester.h</header>
-   <container>0</container>
-   <pixmap></pixmap>
-  </customwidget>
-  <customwidget>
    <class>KCModule</class>
-   <extends></extends>
+   <extends>QWidget</extends>
    <header>kcmodule.h</header>
    <container>1</container>
-   <pixmap></pixmap>
   </customwidget>
+  <customwidget>
+   <class>KIntSpinBox</class>
+   <extends>QSpinBox</extends>
+   <header>knuminput.h</header>
+  </customwidget>
  </customwidgets>
  <resources/>
  <connections/>
Comment 7 Torgny Nyblom 2009-07-22 14:11:23 UTC
Closing with regards to comment #6