<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>351380</bug_id>
          
          <creation_ts>2015-08-16 22:48:29 +0000</creation_ts>
          <short_desc>Ubuntu Mono. Unicode + color =&gt; truncate last character.</short_desc>
          <delta_ts>2015-09-04 20:55:32 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>2</classification_id>
          <classification>Applications</classification>
          <product>konsole</product>
          <component>font</component>
          <version>2.13.2</version>
          <rep_platform>Kubuntu</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>DUPLICATE</resolution>
          <dup_id>297390</dup_id>
          
          <bug_file_loc>http://i.imgur.com/peqm9ti.png</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Konstantin">k-i-r</reporter>
          <assigned_to name="Konsole Bugs">konsole-bugs-null</assigned_to>
          <cc>alexander.kowalski</cc>
          
          <cf_commitlink></cf_commitlink>
          <cf_versionfixedin></cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1537316</commentid>
    <comment_count>0</comment_count>
    <who name="Konstantin">k-i-r</who>
    <bug_when>2015-08-16 22:48:29 +0000</bug_when>
    <thetext>font: Ubuntu Mono.
Print string with unicode characters and terminal colors.
Last character is truncated.

Without colors it works well. Without unicode chars too.
Any other font works fine.

See screenshot for details.

Reproducible: Always

Steps to Reproduce:
1. Set up konsole font to Ubuntu Mono
2. Into konsole:
    &gt; RED=&apos;\033[31m&apos;
    &gt; NC=&apos;\033[0m&apos;
    &gt; printf &quot;${RED}✕ it should be less than 3${NC}\n&quot;     # copy-paste, it is not X.
try
    &gt; printf &quot;✕ it should be less than 3\n&quot;
try
    &gt; printf &quot;${RED} it should be less than 3${NC}\n&quot;
3. Change font and see.

Actual Results:  
Last character of string ugly truncated. Moving the cursor through this string is hard.

Expected Results:  
All should work fine=)

Sorry for my English.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1537396</commentid>
    <comment_count>1</comment_count>
    <who name="Alexander Kowalski">alexander.kowalski</who>
    <bug_when>2015-08-17 09:38:15 +0000</bug_when>
    <thetext>I think this is a duplicate of bug 297390.
I will add some new details there.

Also, the color of the wide letter itself doesn&apos;t change anything; I think that the letters are cut on every boundary between e.g. different colors.
If you try
printf &quot;✕ it should be less than 3${RED} ${NC}\n&quot;
it will still cut off part of the three, and if you try
printf &quot;✕ it should${RED} ${NC}be less than 3\n&quot;
it will cut off part of the d instead.
(Tested on konsole 15.08.0)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1537481</commentid>
    <comment_count>2</comment_count>
    <who name="Konstantin">k-i-r</who>
    <bug_when>2015-08-17 13:29:41 +0000</bug_when>
    <thetext>Result for v 2.13.2 just the same. The letters cut on every boundary between colorized text and not colorized. For example:
&gt; GREEN=&apos;\033[32m&apos;
&gt; printf &quot;✕ it should${RED} be ${GREEN}less ${NC}than 3\n&quot;
&gt;&gt; ✕ it shoul(cut) beless than 3

Also, moving the curson through the string without any colors is hard. Try this
&gt; printf &quot;✕ it should be less than 3\n&quot;  # copy-paste and try to edit the string

Also:
Fonts with problems:
 - Ubuntu Mono
 - TlwgMono
 - Tlwg Typo
 - Oxygen Mono
 - Droid Sans Mono
- Courier 10 Pitch

Fonts without problems:
- Liberation Mono
- DejaVu Sans Mono
- Andale Mono
- Monospace
Courier New
FreeMono</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1537504</commentid>
    <comment_count>3</comment_count>
    <who name="Konstantin">k-i-r</who>
    <bug_when>2015-08-17 14:20:04 +0000</bug_when>
    <thetext>Fix a typo. There are two colors, but only one letter is cut.
&gt; GREEN=&apos;\033[32m&apos;
&gt; printf &quot;✕ it should${RED} be ${GREEN}less ${NC}than 3\n&quot;
&gt;&gt; ✕ it shoul(cut) be less than 3</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1541827</commentid>
    <comment_count>4</comment_count>
    <who name="Kurt Hindenburg">khindenburg</who>
    <bug_when>2015-09-04 20:46:28 +0000</bug_when>
    <thetext>Yes the first X messes up the formatting of the rest of the characters.   The color doesn&apos;t seem to make any difference.

Even my vim doesn&apos;t handle it well

U+2715	✕	e2 9c 95</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1541829</commentid>
    <comment_count>5</comment_count>
    <who name="Kurt Hindenburg">khindenburg</who>
    <bug_when>2015-09-04 20:55:32 +0000</bug_when>
    <thetext>

*** This bug has been marked as a duplicate of bug 297390 ***</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>