emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* bug#34684: 26.1; Strange characters when inserting date
       [not found] <DB7PR01MB41710340234EF2B900832154AF750@DB7PR01MB4171.eurprd01.prod.exchangelabs.com>
@ 2019-02-28 17:55 ` Eli Zaretskii
  2019-02-28 19:11   ` Robert Pluim
  0 siblings, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-02-28 17:55 UTC (permalink / raw)
  To: Wong, Philip; +Cc: 34684

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> Date: Thu, 28 Feb 2019 14:16:25 +0000
> 
> When I insert a date by pressing CTRL+C then period then enter I get “<2019-02-28 ¶g¥|>”.
> 
> I’m not sure what the strange character is (¶g¥|), can someone help?

Please show a complete recipe, starting from "emacs -Q", to reproduce
the issue.  When I type "Ctrl-C ." in "emacs -Q", Emacs says that
sequence is not bound to any command, so I wonder what is needed to
"insert a date" in your scenario.

Thanks.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-02-28 17:55 ` bug#34684: 26.1; Strange characters when inserting date Eli Zaretskii
@ 2019-02-28 19:11   ` Robert Pluim
  2019-02-28 19:15     ` Eric Abrahamsen
  2019-02-28 19:56     ` Eli Zaretskii
  0 siblings, 2 replies; 30+ messages in thread
From: Robert Pluim @ 2019-02-28 19:11 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Wong, Philip, 34684

Eli Zaretskii <eliz@gnu.org> writes:

>> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
>> Date: Thu, 28 Feb 2019 14:16:25 +0000
>> 
>> When I insert a date by pressing CTRL+C then period then enter I get “<2019-02-28 ¶g¥|>”.
>> 
>> I’m not sure what the strange character is (¶g¥|), can someone help?
>
> Please show a complete recipe, starting from "emacs -Q", to reproduce
> the issue.  When I type "Ctrl-C ." in "emacs -Q", Emacs says that
> sequence is not bound to any command, so I wonder what is needed to
> "insert a date" in your scenario.

From the output, this is 'org-time-stamp', which produces
<2019-02-28 Thu> here. Based on this in the report:

    Important settings:
      value of $LANG: ZHH
      locale-coding-system: cp1252

Iʼm assuming thereʼs an issue with buffer-file-coding-system or
similar. If I do

LANG=zh_HK src/emacs -Q
(require 'org)
(org-time-stamp) => <2019-02-28 四>

where that character after the date is CJK IDEOGRAPH-56DB

(and now Iʼve exhausted what I know about Asian characters)

Robert

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: bug#34684: 26.1; Strange characters when inserting date
  2019-02-28 19:11   ` Robert Pluim
@ 2019-02-28 19:15     ` Eric Abrahamsen
  2019-02-28 19:56     ` Eli Zaretskii
  1 sibling, 0 replies; 30+ messages in thread
From: Eric Abrahamsen @ 2019-02-28 19:15 UTC (permalink / raw)
  To: emacs-orgmode

Robert Pluim <rpluim@gmail.com> writes:

> Eli Zaretskii <eliz@gnu.org> writes:
>
>>> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
>>> Date: Thu, 28 Feb 2019 14:16:25 +0000
>>> 
>>> When I insert a date by pressing CTRL+C then period then enter I get “<2019-02-28 ¶g¥|>”.
>>> 
>>> I’m not sure what the strange character is (¶g¥|), can someone help?
>>
>> Please show a complete recipe, starting from "emacs -Q", to reproduce
>> the issue.  When I type "Ctrl-C ." in "emacs -Q", Emacs says that
>> sequence is not bound to any command, so I wonder what is needed to
>> "insert a date" in your scenario.
>
> From the output, this is 'org-time-stamp', which produces
> <2019-02-28 Thu> here. Based on this in the report:
>
>     Important settings:
>       value of $LANG: ZHH
>       locale-coding-system: cp1252
>
> Iʼm assuming thereʼs an issue with buffer-file-coding-system or
> similar. If I do
>
> LANG=zh_HK src/emacs -Q
> (require 'org)
> (org-time-stamp) => <2019-02-28 四>

That means "four", aka "Thursday" :)

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-02-28 19:11   ` Robert Pluim
  2019-02-28 19:15     ` Eric Abrahamsen
@ 2019-02-28 19:56     ` Eli Zaretskii
  2019-03-01 10:00       ` Robert Pluim
  1 sibling, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-02-28 19:56 UTC (permalink / raw)
  To: Robert Pluim; +Cc: Philip.Wong, 34684

> From: Robert Pluim <rpluim@gmail.com>
> Cc: "Wong\, Philip" <Philip.Wong@warwick.ac.uk>,  34684@debbugs.gnu.org
> Date: Thu, 28 Feb 2019 20:11:45 +0100
> 
> Eli Zaretskii <eliz@gnu.org> writes:
> 
> >> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> >> Date: Thu, 28 Feb 2019 14:16:25 +0000
> >> 
> >> When I insert a date by pressing CTRL+C then period then enter I get “<2019-02-28 ¶g¥|>”.
> >> 
> >> I’m not sure what the strange character is (¶g¥|), can someone help?
> >
> > Please show a complete recipe, starting from "emacs -Q", to reproduce
> > the issue.  When I type "Ctrl-C ." in "emacs -Q", Emacs says that
> > sequence is not bound to any command, so I wonder what is needed to
> > "insert a date" in your scenario.
> 
> >From the output, this is 'org-time-stamp', which produces
> <2019-02-28 Thu> here. Based on this in the report:
> 
>     Important settings:
>       value of $LANG: ZHH
>       locale-coding-system: cp1252
> 
> Iʼm assuming thereʼs an issue with buffer-file-coding-system or
> similar.

Unlikely: buffer-file-coding-system has no effect whatsoever on the
text that is inserted into a buffer, it only has effect when you want
to save the buffer or send it to some sub-process.

It could be some snafu in Org, though, e.,g. if it doesn't know how to
support that value of $LANG.  In any case, should be reported to Org
developers first.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-02-28 19:56     ` Eli Zaretskii
@ 2019-03-01 10:00       ` Robert Pluim
  2019-03-01 10:35         ` Eli Zaretskii
  0 siblings, 1 reply; 30+ messages in thread
From: Robert Pluim @ 2019-03-01 10:00 UTC (permalink / raw)
  To: Philip.Wong; +Cc: Eli Zaretskii, 34684

Eli Zaretskii <eliz@gnu.org> writes:

>> Iʼm assuming thereʼs an issue with buffer-file-coding-system or
>> similar.
>
> Unlikely: buffer-file-coding-system has no effect whatsoever on the
> text that is inserted into a buffer, it only has effect when you want
> to save the buffer or send it to some sub-process.
>
> It could be some snafu in Org, though, e.,g. if it doesn't know how to
> support that value of $LANG.  In any case, should be reported to Org
> developers first.

org-time-stamp just calls essentially

(insert (format-time-string "<%Y-%m-%d %a>" (current-time)))

so itʼs hard to see how this could be an issue in Org.

Does this happen when running 'emacs -Q'?

Robert

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-01 10:00       ` Robert Pluim
@ 2019-03-01 10:35         ` Eli Zaretskii
  2019-03-01 13:47           ` Robert Pluim
  0 siblings, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-01 10:35 UTC (permalink / raw)
  To: Robert Pluim; +Cc: Philip.Wong, 34684

> From: Robert Pluim <rpluim@gmail.com>
> Cc: Eli Zaretskii <eliz@gnu.org>,  34684@debbugs.gnu.org
> Date: Fri, 01 Mar 2019 11:00:01 +0100
> 
> > It could be some snafu in Org, though, e.,g. if it doesn't know how to
> > support that value of $LANG.  In any case, should be reported to Org
> > developers first.
> 
> org-time-stamp just calls essentially
> 
> (insert (format-time-string "<%Y-%m-%d %a>" (current-time)))
> 
> so itʼs hard to see how this could be an issue in Org.

That's only so if the above produces the same garbled result as in the
original report.  Does it?

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-01 10:35         ` Eli Zaretskii
@ 2019-03-01 13:47           ` Robert Pluim
  2019-03-01 13:49             ` Robert Pluim
  2019-03-01 14:09             ` Eli Zaretskii
  0 siblings, 2 replies; 30+ messages in thread
From: Robert Pluim @ 2019-03-01 13:47 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Philip.Wong, 34684

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Robert Pluim <rpluim@gmail.com>
>> Cc: Eli Zaretskii <eliz@gnu.org>,  34684@debbugs.gnu.org
>> Date: Fri, 01 Mar 2019 11:00:01 +0100
>> 
>> > It could be some snafu in Org, though, e.,g. if it doesn't know how to
>> > support that value of $LANG.  In any case, should be reported to Org
>> > developers first.
>> 
>> org-time-stamp just calls essentially
>> 
>> (insert (format-time-string "<%Y-%m-%d %a>" (current-time)))
>> 
>> so itʼs hard to see how this could be an issue in Org.
>
> That's only so if the above produces the same garbled result as in the
> original report.  Does it?

Didnʼt I send this yesterday?

$ LANG=zh_HK src/emacs -Q -l ss.el
(require 'org)
(org-time-stamp)
<2019-03-01 五>

I think '五' is 'Five', but donʼt quote me on that.

So at least for me itʼs working correctly (in both *scratch* and an
Org-mode buffer), which means thereʼs something wrong in the
reporter's configuration somewhere.

Robert

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-01 13:47           ` Robert Pluim
@ 2019-03-01 13:49             ` Robert Pluim
  2019-03-01 14:09             ` Eli Zaretskii
  1 sibling, 0 replies; 30+ messages in thread
From: Robert Pluim @ 2019-03-01 13:49 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Philip.Wong, 34684

Robert Pluim <rpluim@gmail.com> writes:

> Eli Zaretskii <eliz@gnu.org> writes:
>
>>> From: Robert Pluim <rpluim@gmail.com>
>>> Cc: Eli Zaretskii <eliz@gnu.org>,  34684@debbugs.gnu.org
>>> Date: Fri, 01 Mar 2019 11:00:01 +0100
>>> 
>>> > It could be some snafu in Org, though, e.,g. if it doesn't know how to
>>> > support that value of $LANG.  In any case, should be reported to Org
>>> > developers first.
>>> 
>>> org-time-stamp just calls essentially
>>> 
>>> (insert (format-time-string "<%Y-%m-%d %a>" (current-time)))
>>> 
>>> so itʼs hard to see how this could be an issue in Org.
>>
>> That's only so if the above produces the same garbled result as in the
>> original report.  Does it?
>
> Didnʼt I send this yesterday?
>
> $ LANG=zh_HK src/emacs -Q -l ss.el
> (require 'org)
> (org-time-stamp)
> <2019-03-01 五>
>
> I think '五' is 'Five', but donʼt quote me on that.
>
> So at least for me itʼs working correctly (in both *scratch* and an
> Org-mode buffer), which means thereʼs something wrong in the
> reporter's configuration somewhere.

And also

(insert (format-time-string "<%Y-%m-%d %a>" (current-time)))

produces the same result for me.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-01 13:47           ` Robert Pluim
  2019-03-01 13:49             ` Robert Pluim
@ 2019-03-01 14:09             ` Eli Zaretskii
  2019-03-01 14:25               ` Robert Pluim
  1 sibling, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-01 14:09 UTC (permalink / raw)
  To: Robert Pluim; +Cc: Philip.Wong, 34684

> From: Robert Pluim <rpluim@gmail.com>
> Cc: Philip.Wong@warwick.ac.uk,  34684@debbugs.gnu.org
> Date: Fri, 01 Mar 2019 14:47:21 +0100
> 
> > That's only so if the above produces the same garbled result as in the
> > original report.  Does it?
> 
> Didnʼt I send this yesterday?
> 
> $ LANG=zh_HK src/emacs -Q -l ss.el
> (require 'org)
> (org-time-stamp)
> <2019-03-01 五>
> 
> I think '五' is 'Five', but donʼt quote me on that.

This is not garbage by any measure.  Please compare with what the OP
reported.

In any case, the original report was for Thursday, not Friday.  the
former should AFAIU display 四.  But neither is nowhere close to the
sequence the OP reported, not even if I break the correct character
into individual bytes, so some other factor is at work here.

> So at least for me itʼs working correctly (in both *scratch* and an
> Org-mode buffer), which means thereʼs something wrong in the
> reporter's configuration somewhere.

What, if anything, is wrong with the OP's configuration is exactly the
issue here.  There's no question that current-time and
format-time-string work in general.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-01 14:09             ` Eli Zaretskii
@ 2019-03-01 14:25               ` Robert Pluim
  2019-03-01 14:42                 ` Eli Zaretskii
  0 siblings, 1 reply; 30+ messages in thread
From: Robert Pluim @ 2019-03-01 14:25 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Philip.Wong, 34684

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Robert Pluim <rpluim@gmail.com>
>> Cc: Philip.Wong@warwick.ac.uk,  34684@debbugs.gnu.org
>> Date: Fri, 01 Mar 2019 14:47:21 +0100
>> 
>> > That's only so if the above produces the same garbled result as in the
>> > original report.  Does it?
>> 
>> Didnʼt I send this yesterday?
>> 
>> $ LANG=zh_HK src/emacs -Q -l ss.el
>> (require 'org)
>> (org-time-stamp)
>> <2019-03-01 五>
>> 
>> I think '五' is 'Five', but donʼt quote me on that.
>
> This is not garbage by any measure.  Please compare with what the OP
> reported.

We are miscommunicating. I was demonstrating that in my setup,
org-time-stamp produces the correct output => itʼs a configuration
issue.

> What, if anything, is wrong with the OP's configuration is exactly the
> issue here.

Right.

Robert

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-01 14:25               ` Robert Pluim
@ 2019-03-01 14:42                 ` Eli Zaretskii
  2019-03-11  9:41                   ` Wong, Philip
  0 siblings, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-01 14:42 UTC (permalink / raw)
  To: Robert Pluim; +Cc: Philip.Wong, 34684

> From: Robert Pluim <rpluim@gmail.com>
> Cc: Philip.Wong@warwick.ac.uk,  34684@debbugs.gnu.org
> Date: Fri, 01 Mar 2019 15:25:04 +0100
> 
> We are miscommunicating. I was demonstrating that in my setup,
> org-time-stamp produces the correct output => itʼs a configuration
> issue.

I'm not yet sure it's a configuration issue.  It could be some bug
specific to Windows.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-01 14:42                 ` Eli Zaretskii
@ 2019-03-11  9:41                   ` Wong, Philip
  2019-03-11 10:43                     ` Robert Pluim
  2019-03-11 14:45                     ` Eli Zaretskii
  0 siblings, 2 replies; 30+ messages in thread
From: Wong, Philip @ 2019-03-11  9:41 UTC (permalink / raw)
  To: Eli Zaretskii, Robert Pluim; +Cc: 34684

Sorry, I don't understand what you mean by emacs -Q.

How exactly am I supposed to run this command? 

I tried ctrl c and then started typing 'emacs -Q' but it did nothing.

-----Original Message-----
From: Eli Zaretskii <eliz@gnu.org> 
Sent: Friday, March 1, 2019 2:43 PM
To: Robert Pluim <rpluim@gmail.com>
Cc: Wong, Philip <Philip.Wong@warwick.ac.uk>; 34684@debbugs.gnu.org
Subject: Re: bug#34684: 26.1; Strange characters when inserting date

> From: Robert Pluim <rpluim@gmail.com>
> Cc: Philip.Wong@warwick.ac.uk,  34684@debbugs.gnu.org
> Date: Fri, 01 Mar 2019 15:25:04 +0100
> 
> We are miscommunicating. I was demonstrating that in my setup, 
> org-time-stamp produces the correct output => itʼs a configuration 
> issue.

I'm not yet sure it's a configuration issue.  It could be some bug specific to Windows.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11  9:41                   ` Wong, Philip
@ 2019-03-11 10:43                     ` Robert Pluim
  2019-03-11 10:47                       ` Wong, Philip
  2019-03-11 14:45                     ` Eli Zaretskii
  1 sibling, 1 reply; 30+ messages in thread
From: Robert Pluim @ 2019-03-11 10:43 UTC (permalink / raw)
  To: Wong, Philip; +Cc: Eli Zaretskii, 34684

>>>>> On Mon, 11 Mar 2019 09:41:41 +0000, "Wong, Philip" <Philip.Wong@warwick.ac.uk> said:

    Philip> Sorry, I don't understand what you mean by emacs -Q.  How
    Philip> exactly am I supposed to run this command?

    Philip> I tried ctrl c and then started typing 'emacs -Q' but it
    Philip> did nothing.

I guess youʼre starting emacs by clicking on some icon? You need to
start it from the command line, with an argument of -Q, probably from
cmd.exe or similar (I am Emacs-on-windows ignorant).

Robert

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 10:43                     ` Robert Pluim
@ 2019-03-11 10:47                       ` Wong, Philip
  2019-03-11 14:58                         ` Eli Zaretskii
  2019-03-12  3:42                         ` bug#34684: " Takaaki Ishikawa
  0 siblings, 2 replies; 30+ messages in thread
From: Wong, Philip @ 2019-03-11 10:47 UTC (permalink / raw)
  To: Robert Pluim; +Cc: Eli Zaretskii, 34684


[-- Attachment #1.1: Type: text/plain, Size: 942 bytes --]

Does the same thing



[cid:image001.png@01D4D7F7.C09967C0]







-----Original Message-----
From: Robert Pluim <rpluim@gmail.com>
Sent: Monday, March 11, 2019 10:43 AM
To: Wong, Philip <Philip.Wong@warwick.ac.uk>
Cc: Eli Zaretskii <eliz@gnu.org>; 34684@debbugs.gnu.org
Subject: Re: bug#34684: 26.1; Strange characters when inserting date



>>>>> On Mon, 11 Mar 2019 09:41:41 +0000, "Wong, Philip" <Philip.Wong@warwick.ac.uk<mailto:Philip.Wong@warwick.ac.uk>> said:



    Philip> Sorry, I don't understand what you mean by emacs -Q.  How

    Philip> exactly am I supposed to run this command?



    Philip> I tried ctrl c and then started typing 'emacs -Q' but it

    Philip> did nothing.



I guess youʼre starting emacs by clicking on some icon? You need to start it from the command line, with an argument of -Q, probably from cmd.exe or similar (I am Emacs-on-windows ignorant).



Robert

[-- Attachment #1.2: Type: text/html, Size: 4230 bytes --]

[-- Attachment #2: image001.png --]
[-- Type: image/png, Size: 22875 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11  9:41                   ` Wong, Philip
  2019-03-11 10:43                     ` Robert Pluim
@ 2019-03-11 14:45                     ` Eli Zaretskii
  1 sibling, 0 replies; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-11 14:45 UTC (permalink / raw)
  To: Wong, Philip; +Cc: rpluim, 34684

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: "34684@debbugs.gnu.org" <34684@debbugs.gnu.org>
> Date: Mon, 11 Mar 2019 09:41:41 +0000
> 
> Sorry, I don't understand what you mean by emacs -Q.
> 
> How exactly am I supposed to run this command? 

Open the Windows command window that runs cmd.exe, and type "emacs -Q"
there.  Then press the [Enter] key.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 10:47                       ` Wong, Philip
@ 2019-03-11 14:58                         ` Eli Zaretskii
       [not found]                           ` <DB7PR01MB4171B6AF4751C4D196E19DECAF480@DB7PR01MB4171.eurprd01.prod.exchangelabs.com>
  2019-03-12  3:42                         ` bug#34684: " Takaaki Ishikawa
  1 sibling, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-11 14:58 UTC (permalink / raw)
  To: Wong, Philip; +Cc: rpluim, 34684

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: Eli Zaretskii <eliz@gnu.org>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Mon, 11 Mar 2019 10:47:00 +0000
> 
> Does the same thing

OK.  Can you send the list of abbreviated weekdays in your locale's
language, as you expect them to be displayed?  Please send them as
text, not as images.

Also, does this display the data correctly:

  M-: (insert (format-time-string "<%Y-%m-%d %a>" (current-time))) RET

or does it insert the same garbled characters?

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
       [not found]                           ` <DB7PR01MB4171B6AF4751C4D196E19DECAF480@DB7PR01MB4171.eurprd01.prod.exchangelabs.com>
@ 2019-03-11 16:41                             ` Robert Pluim
  2019-03-11 16:43                               ` Wong, Philip
  0 siblings, 1 reply; 30+ messages in thread
From: Robert Pluim @ 2019-03-11 16:41 UTC (permalink / raw)
  To: Wong, Philip; +Cc: Eli Zaretskii, 34684

>>>>> On Mon, 11 Mar 2019 16:13:16 +0000, "Wong, Philip" <Philip.Wong@warwick.ac.uk> said:

    Philip> Chinese, Sunday to Saturday:日一二三四五六

    Philip> Attempting M-: (I hope I did this right, I pressed Alt +
    Philip> Shift + :, then copied and pasted your command)

    Philip> No output but it says this on the bottom: 'Trailing
    Philip> garbage following expression'

I guess that means you typed literally ' RET'. Eli meant: type the
command up to the closing ')', and then hit the 'Enter' key, which we
normally refer to as 'RET'.

Robert

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 16:41                             ` Robert Pluim
@ 2019-03-11 16:43                               ` Wong, Philip
  2019-03-11 16:54                                 ` Eli Zaretskii
  0 siblings, 1 reply; 30+ messages in thread
From: Wong, Philip @ 2019-03-11 16:43 UTC (permalink / raw)
  To: Robert Pluim; +Cc: Eli Zaretskii, 34684

I can confirm that I did press Enter, I assumed that meant Return already.

-----Original Message-----
From: Robert Pluim <rpluim@gmail.com> 
Sent: Monday, March 11, 2019 4:42 PM
To: Wong, Philip <Philip.Wong@warwick.ac.uk>
Cc: Eli Zaretskii <eliz@gnu.org>; 34684@debbugs.gnu.org
Subject: Re: bug#34684: 26.1; Strange characters when inserting date

>>>>> On Mon, 11 Mar 2019 16:13:16 +0000, "Wong, Philip" <Philip.Wong@warwick.ac.uk> said:

    Philip> Chinese, Sunday to Saturday:日一二三四五六

    Philip> Attempting M-: (I hope I did this right, I pressed Alt +
    Philip> Shift + :, then copied and pasted your command)

    Philip> No output but it says this on the bottom: 'Trailing
    Philip> garbage following expression'

I guess that means you typed literally ' RET'. Eli meant: type the command up to the closing ')', and then hit the 'Enter' key, which we normally refer to as 'RET'.

Robert

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 16:43                               ` Wong, Philip
@ 2019-03-11 16:54                                 ` Eli Zaretskii
  2019-03-11 16:55                                   ` Wong, Philip
  0 siblings, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-11 16:54 UTC (permalink / raw)
  To: Wong, Philip; +Cc: rpluim, 34684

> X-Spam-Status: No, score=3.3 required=5.0 tests=BAYES_50,RCVD_IN_DNSWL_NONE,
> 	RECEIVED_FROM_WINDOWS_HOST,URIBL_BLOCKED autolearn=disabled version=3.3.2
> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: Eli Zaretskii <eliz@gnu.org>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Mon, 11 Mar 2019 16:43:00 +0000
> Accept-Language: en-GB, ja-JP, en-US
> 
> I can confirm that I did press Enter, I assumed that meant Return already.
> 
> -----Original Message-----
> From: Robert Pluim <rpluim@gmail.com> 
> Sent: Monday, March 11, 2019 4:42 PM
> To: Wong, Philip <Philip.Wong@warwick.ac.uk>
> Cc: Eli Zaretskii <eliz@gnu.org>; 34684@debbugs.gnu.org
> Subject: Re: bug#34684: 26.1; Strange characters when inserting date
> 
> >>>>> On Mon, 11 Mar 2019 16:13:16 +0000, "Wong, Philip" <Philip.Wong@warwick.ac.uk> said:
> 
>     Philip> Chinese, Sunday to Saturday:日一二三四五六
> 
>     Philip> Attempting M-: (I hope I did this right, I pressed Alt +
>     Philip> Shift + :, then copied and pasted your command)
> 
>     Philip> No output but it says this on the bottom: 'Trailing
>     Philip> garbage following expression'
> 
> I guess that means you typed literally ' RET'. Eli meant: type the command up to the closing ')', and then hit the 'Enter' key, which we normally refer to as 'RET'.

Then please make sure you type 3 closing parentheses at the end, not
4.  If I type 4, I get the same response as you describe.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 16:54                                 ` Eli Zaretskii
@ 2019-03-11 16:55                                   ` Wong, Philip
  2019-03-11 17:29                                     ` Eli Zaretskii
  0 siblings, 1 reply; 30+ messages in thread
From: Wong, Philip @ 2019-03-11 16:55 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: rpluim, 34684

Thanks Eli, you're right.

I still get '<2019-03-11 ¶g¤@>'

-----Original Message-----
From: Eli Zaretskii <eliz@gnu.org> 
Sent: Monday, March 11, 2019 4:54 PM
To: Wong, Philip <Philip.Wong@warwick.ac.uk>
Cc: rpluim@gmail.com; 34684@debbugs.gnu.org
Subject: Re: bug#34684: 26.1; Strange characters when inserting date

> X-Spam-Status: No, score=3.3 required=5.0 tests=BAYES_50,RCVD_IN_DNSWL_NONE,
> 	RECEIVED_FROM_WINDOWS_HOST,URIBL_BLOCKED autolearn=disabled 
> version=3.3.2
> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: Eli Zaretskii <eliz@gnu.org>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Mon, 11 Mar 2019 16:43:00 +0000
> Accept-Language: en-GB, ja-JP, en-US
> 
> I can confirm that I did press Enter, I assumed that meant Return already.
> 
> -----Original Message-----
> From: Robert Pluim <rpluim@gmail.com>
> Sent: Monday, March 11, 2019 4:42 PM
> To: Wong, Philip <Philip.Wong@warwick.ac.uk>
> Cc: Eli Zaretskii <eliz@gnu.org>; 34684@debbugs.gnu.org
> Subject: Re: bug#34684: 26.1; Strange characters when inserting date
> 
> >>>>> On Mon, 11 Mar 2019 16:13:16 +0000, "Wong, Philip" <Philip.Wong@warwick.ac.uk> said:
> 
>     Philip> Chinese, Sunday to Saturday:日一二三四五六
> 
>     Philip> Attempting M-: (I hope I did this right, I pressed Alt +
>     Philip> Shift + :, then copied and pasted your command)
> 
>     Philip> No output but it says this on the bottom: 'Trailing
>     Philip> garbage following expression'
> 
> I guess that means you typed literally ' RET'. Eli meant: type the command up to the closing ')', and then hit the 'Enter' key, which we normally refer to as 'RET'.

Then please make sure you type 3 closing parentheses at the end, not 4.  If I type 4, I get the same response as you describe.



^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 16:55                                   ` Wong, Philip
@ 2019-03-11 17:29                                     ` Eli Zaretskii
  2019-03-11 17:35                                       ` Wong, Philip
  0 siblings, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-11 17:29 UTC (permalink / raw)
  To: Wong, Philip; +Cc: rpluim, 34684

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: "rpluim@gmail.com" <rpluim@gmail.com>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Mon, 11 Mar 2019 16:55:42 +0000
> 
> Thanks Eli, you're right.
> 
> I still get '<2019-03-11 ¶g¤@>'

OK, as expected.  This means Org is indeed off the hook, the problem
is with format-time-string and/or the Windows implementation of the
strftime function.

Does the below produce correct  results, or does it also produce
garbled strings:

  M-: (insert (format-time-string "<%Y-%m-%d %A>" (current-time))) RET

This is the same as what you tried, but with capital %A instead of
lower-case %a.  %A should produce the full name of the weekday.

Also, please evaluate each of the following expressions with
M-: ... RET (replace the "..." with each expression below), and
please tell what each of them produced:

    (w32-get-current-locale-id)
    (w32-get-locale-info (w32-get-current-locale-id) t)
    (w32-get-default-locale-id)
    (w32-get-default-locale-id t)
    (locale-info 'days)

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 17:29                                     ` Eli Zaretskii
@ 2019-03-11 17:35                                       ` Wong, Philip
  2019-03-11 17:55                                         ` Eli Zaretskii
  0 siblings, 1 reply; 30+ messages in thread
From: Wong, Philip @ 2019-03-11 17:35 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: rpluim, 34684

Here is the output in the order of commands you mentioned:
<2019-03-11 ¬P´Á¤@>

For the other commands, there is no output in the actual buffer) but on the bottom it says....
3076 (#o6004, #xc04)
"?? (??,???????)"
1033 (#o2011, #x409)
3076 (#o6004, #xc04)
["???" "???" "???" "???" "???" "???" "???"]    

-----Original Message-----
From: Eli Zaretskii <eliz@gnu.org> 
Sent: Monday, March 11, 2019 5:30 PM
To: Wong, Philip <Philip.Wong@warwick.ac.uk>
Cc: rpluim@gmail.com; 34684@debbugs.gnu.org
Subject: Re: bug#34684: 26.1; Strange characters when inserting date

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: "rpluim@gmail.com" <rpluim@gmail.com>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Mon, 11 Mar 2019 16:55:42 +0000
> 
> Thanks Eli, you're right.
> 
> I still get '<2019-03-11 ¶g¤@>'

OK, as expected.  This means Org is indeed off the hook, the problem is with format-time-string and/or the Windows implementation of the strftime function.

Does the below produce correct  results, or does it also produce garbled strings:

  M-: (insert (format-time-string "<%Y-%m-%d %A>" (current-time))) RET

This is the same as what you tried, but with capital %A instead of lower-case %a.  %A should produce the full name of the weekday.

Also, please evaluate each of the following expressions with
M-: ... RET (replace the "..." with each expression below), and please tell what each of them produced:

    (w32-get-current-locale-id)
    (w32-get-locale-info (w32-get-current-locale-id) t)
    (w32-get-default-locale-id)
    (w32-get-default-locale-id t)
    (locale-info 'days)

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 17:35                                       ` Wong, Philip
@ 2019-03-11 17:55                                         ` Eli Zaretskii
  2019-03-12  9:58                                           ` Wong, Philip
  0 siblings, 1 reply; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-11 17:55 UTC (permalink / raw)
  To: Wong, Philip; +Cc: rpluim, 34684

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: "rpluim@gmail.com" <rpluim@gmail.com>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Mon, 11 Mar 2019 17:35:05 +0000
> 
> Here is the output in the order of commands you mentioned:
> <2019-03-11 ¬P´Á¤@>
> 
> For the other commands, there is no output in the actual buffer) but on the bottom it says....
> 3076 (#o6004, #xc04)
> "?? (??,???????)"
> 1033 (#o2011, #x409)
> 3076 (#o6004, #xc04)
> ["???" "???" "???" "???" "???" "???" "???"]    

Thanks, I think I understand what happens.  The problem is that your
locale produces day names that cannot be represented with codepage
1252, so you get garbled strings and question marks instead.

Does it help to change the value of locale-coding-system, like below?

  M-: (setq locale-coding-system 'cp950)

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684:  bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 10:47                       ` Wong, Philip
  2019-03-11 14:58                         ` Eli Zaretskii
@ 2019-03-12  3:42                         ` Takaaki Ishikawa
  2019-03-12 15:53                           ` Eli Zaretskii
  1 sibling, 1 reply; 30+ messages in thread
From: Takaaki Ishikawa @ 2019-03-12  3:42 UTC (permalink / raw)
  To: Wong, Philip; +Cc: Robert Pluim, Eli Zaretskii, 34684


[-- Attachment #1.1: Type: text/plain, Size: 1251 bytes --]

Hi folks,

Have you tried to use `set-local-environment'?
I usually use the command to change the date formatting in my init.el as
follows:

(set-locale-environment "en_US.UTF-8") ;; "ja_JP.UTF-8"

Best  regards,
Takaaki Ishikawa


2019年3月12日(火) 3:34 Wong, Philip <Philip.Wong@warwick.ac.uk>:

> Does the same thing
>
>
>
>
>
>
>
>
>
> -----Original Message-----
> From: Robert Pluim <rpluim@gmail.com>
> Sent: Monday, March 11, 2019 10:43 AM
> To: Wong, Philip <Philip.Wong@warwick.ac.uk>
> Cc: Eli Zaretskii <eliz@gnu.org>; 34684@debbugs.gnu.org
> Subject: Re: bug#34684: 26.1; Strange characters when inserting date
>
>
>
> >>>>> On Mon, 11 Mar 2019 09:41:41 +0000, "Wong, Philip" <
> Philip.Wong@warwick.ac.uk> said:
>
>
>
>     Philip> Sorry, I don't understand what you mean by emacs -Q.  How
>
>     Philip> exactly am I supposed to run this command?
>
>
>
>     Philip> I tried ctrl c and then started typing 'emacs -Q' but it
>
>     Philip> did nothing.
>
>
>
> I guess youʼre starting emacs by clicking on some icon? You need to start
> it from the command line, with an argument of -Q, probably from cmd.exe or
> similar (I am Emacs-on-windows ignorant).
>
>
>
> Robert
>

[-- Attachment #1.2: Type: text/html, Size: 3641 bytes --]

[-- Attachment #2: image001.png --]
[-- Type: image/png, Size: 22875 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-11 17:55                                         ` Eli Zaretskii
@ 2019-03-12  9:58                                           ` Wong, Philip
  2019-03-12 16:01                                             ` Eli Zaretskii
  0 siblings, 1 reply; 30+ messages in thread
From: Wong, Philip @ 2019-03-12  9:58 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: rpluim, 34684

That did the job, thanks!


-----Original Message-----
From: Eli Zaretskii <eliz@gnu.org> 
Sent: Monday, March 11, 2019 5:55 PM
To: Wong, Philip <Philip.Wong@warwick.ac.uk>
Cc: rpluim@gmail.com; 34684@debbugs.gnu.org
Subject: Re: bug#34684: 26.1; Strange characters when inserting date

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: "rpluim@gmail.com" <rpluim@gmail.com>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Mon, 11 Mar 2019 17:35:05 +0000
> 
> Here is the output in the order of commands you mentioned:
> <2019-03-11 ¬P´Á¤@>
> 
> For the other commands, there is no output in the actual buffer) but on the bottom it says....
> 3076 (#o6004, #xc04)
> "?? (??,???????)"
> 1033 (#o2011, #x409)
> 3076 (#o6004, #xc04)
> ["???" "???" "???" "???" "???" "???" "???"]    

Thanks, I think I understand what happens.  The problem is that your locale produces day names that cannot be represented with codepage 1252, so you get garbled strings and question marks instead.

Does it help to change the value of locale-coding-system, like below?

  M-: (setq locale-coding-system 'cp950)

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684:  bug#34684: 26.1; Strange characters when inserting date
  2019-03-12  3:42                         ` bug#34684: " Takaaki Ishikawa
@ 2019-03-12 15:53                           ` Eli Zaretskii
  0 siblings, 0 replies; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-12 15:53 UTC (permalink / raw)
  To: Takaaki Ishikawa; +Cc: Philip.Wong, rpluim, 34684

> From: Takaaki Ishikawa <takaxp@ieee.org>
> Date: Tue, 12 Mar 2019 12:42:39 +0900
> Cc: Robert Pluim <rpluim@gmail.com>, Eli Zaretskii <eliz@gnu.org>, 
> 	"34684@debbugs.gnu.org" <34684@debbugs.gnu.org>
> 
> Have you tried to use `set-local-environment'?
> I usually use the command to change the date formatting in my init.el as follows:
> 
> (set-locale-environment "en_US.UTF-8") ;; "ja_JP.UTF-8"

You are on GNU/Linux, right?  Because the above will not work on
Windows, because UTF-8 os not reliably supported, not even in Windows
10 (which added some improvements in that area).

But perhaps this could help:

  (set-language-environment "Chinese-Big5")

However, it's possible that even this will not help, unless the system
codepage is changed to something that can support Chinese.

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-12  9:58                                           ` Wong, Philip
@ 2019-03-12 16:01                                             ` Eli Zaretskii
  2019-03-12 16:04                                               ` Wong, Philip
  2020-05-22 12:10                                               ` Bastien
  0 siblings, 2 replies; 30+ messages in thread
From: Eli Zaretskii @ 2019-03-12 16:01 UTC (permalink / raw)
  To: Wong, Philip; +Cc: rpluim, 34684

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: "rpluim@gmail.com" <rpluim@gmail.com>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Tue, 12 Mar 2019 09:58:17 +0000
> 
> That did the job, thanks!

OK, thanks.  I guess we will need to try doing this automatically at
startup...

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-12 16:01                                             ` Eli Zaretskii
@ 2019-03-12 16:04                                               ` Wong, Philip
  2020-05-22 12:10                                               ` Bastien
  1 sibling, 0 replies; 30+ messages in thread
From: Wong, Philip @ 2019-03-12 16:04 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: rpluim, 34684

FTR I'm running Windows 10

-----Original Message-----
From: Eli Zaretskii <eliz@gnu.org> 
Sent: Tuesday, March 12, 2019 4:01 PM
To: Wong, Philip <Philip.Wong@warwick.ac.uk>
Cc: rpluim@gmail.com; 34684@debbugs.gnu.org
Subject: Re: bug#34684: 26.1; Strange characters when inserting date

> From: "Wong, Philip" <Philip.Wong@warwick.ac.uk>
> CC: "rpluim@gmail.com" <rpluim@gmail.com>, "34684@debbugs.gnu.org"
> 	<34684@debbugs.gnu.org>
> Date: Tue, 12 Mar 2019 09:58:17 +0000
> 
> That did the job, thanks!

OK, thanks.  I guess we will need to try doing this automatically at startup...

^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2019-03-12 16:01                                             ` Eli Zaretskii
  2019-03-12 16:04                                               ` Wong, Philip
@ 2020-05-22 12:10                                               ` Bastien
  2020-05-22 12:18                                                 ` Eli Zaretskii
  1 sibling, 1 reply; 30+ messages in thread
From: Bastien @ 2020-05-22 12:10 UTC (permalink / raw)
  To: Eli Zaretskii; +Cc: Wong, Philip, rpluim, 34684

It seems like the bug is not related to org-mode.

I'd like to "unassign" the bug report from org-mode, but
I am not sure how to do that.  If anyone can help, thanks.

-- 
 Bastien




^ permalink raw reply	[flat|nested] 30+ messages in thread

* bug#34684: 26.1; Strange characters when inserting date
  2020-05-22 12:10                                               ` Bastien
@ 2020-05-22 12:18                                                 ` Eli Zaretskii
  0 siblings, 0 replies; 30+ messages in thread
From: Eli Zaretskii @ 2020-05-22 12:18 UTC (permalink / raw)
  To: Bastien; +Cc: Philip.Wong, rpluim, 34684-done

> From: Bastien <bzg@gnu.org>
> Cc: "Wong, Philip" <Philip.Wong@warwick.ac.uk>,  rpluim@gmail.com,
>   34684@debbugs.gnu.org
> Date: Fri, 22 May 2020 14:10:21 +0200
> 
> It seems like the bug is not related to org-mode.

It isn't, but it can also be closed.  Which I did.

Thanks.




^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2020-05-22 12:19 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <DB7PR01MB41710340234EF2B900832154AF750@DB7PR01MB4171.eurprd01.prod.exchangelabs.com>
2019-02-28 17:55 ` bug#34684: 26.1; Strange characters when inserting date Eli Zaretskii
2019-02-28 19:11   ` Robert Pluim
2019-02-28 19:15     ` Eric Abrahamsen
2019-02-28 19:56     ` Eli Zaretskii
2019-03-01 10:00       ` Robert Pluim
2019-03-01 10:35         ` Eli Zaretskii
2019-03-01 13:47           ` Robert Pluim
2019-03-01 13:49             ` Robert Pluim
2019-03-01 14:09             ` Eli Zaretskii
2019-03-01 14:25               ` Robert Pluim
2019-03-01 14:42                 ` Eli Zaretskii
2019-03-11  9:41                   ` Wong, Philip
2019-03-11 10:43                     ` Robert Pluim
2019-03-11 10:47                       ` Wong, Philip
2019-03-11 14:58                         ` Eli Zaretskii
     [not found]                           ` <DB7PR01MB4171B6AF4751C4D196E19DECAF480@DB7PR01MB4171.eurprd01.prod.exchangelabs.com>
2019-03-11 16:41                             ` Robert Pluim
2019-03-11 16:43                               ` Wong, Philip
2019-03-11 16:54                                 ` Eli Zaretskii
2019-03-11 16:55                                   ` Wong, Philip
2019-03-11 17:29                                     ` Eli Zaretskii
2019-03-11 17:35                                       ` Wong, Philip
2019-03-11 17:55                                         ` Eli Zaretskii
2019-03-12  9:58                                           ` Wong, Philip
2019-03-12 16:01                                             ` Eli Zaretskii
2019-03-12 16:04                                               ` Wong, Philip
2020-05-22 12:10                                               ` Bastien
2020-05-22 12:18                                                 ` Eli Zaretskii
2019-03-12  3:42                         ` bug#34684: " Takaaki Ishikawa
2019-03-12 15:53                           ` Eli Zaretskii
2019-03-11 14:45                     ` Eli Zaretskii

Code repositories for project(s) associated with this inbox:

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).