Re: Understanding Unicode Characters

2018-12-21 Thread Robert ListMail via 4D_Tech
Hi Arnaud, thanks for the clarification. 

Robert

Sent from my iPhone

> On Dec 21, 2018, at 6:54 AM, Arnaud de Montard via 4D_Tech 
> <4d_tech@lists.4d.com> wrote:
> 
> In the good old ascii, decimal 165 (hex 0xA5) was represented by a bullet, as 
> you cas see in the range 128..255:
> 
> But in this range, the resulting char could vary, depending on the OS 
> "flavour" (see bottom of list, many codes were represented on mac with no 
> equivalent on windows). 
> In unicode, one code = one char and, definitely, 165 is "¥" and 0x2022 is "•".

**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

Re: Understanding Unicode Characters

2018-12-21 Thread Arnaud de Montard via 4D_Tech

> Le 20 déc. 2018 à 00:07, Robert ListMail via 4D_Tech <4d_tech@lists.4d.com> a 
> écrit :
> 
> [...] why is the unicode value written as “U+2022”, do you ever have to type 
> “U+”?


Hi Robert, 
you can use an hex value in 4d code by replacing "U+" with "0x":
  ASSERT(8226=0x2022)
  $bullet:=Character(0x2022)
  $bullet:=Character(8226)

In the good old ascii, decimal 165 (hex 0xA5) was represented by a bullet, as 
you cas see in the range 128..255:

But in this range, the resulting char could vary, depending on the OS "flavour" 
(see bottom of list, many codes were represented on mac with no equivalent on 
windows). 
In unicode, one code = one char and, definitely, 165 is "¥" and 0x2022 is "•". 

-- 
Arnaud de Montard 



**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: Understanding Unicode Characters

2018-12-19 Thread Timothy Penner via 4D_Tech
In case it wasn't clear -

Unicode U+2022 is the hex value, which corresponds to the decimal value of 
8226. 4D expects a longint which is the decimal value of 8226.
See more here: https://www.fileformat.info/info/unicode/char/2022/index.htm

Now for Char(165) this would equate to U+A5 which is listed here:
http://www.fileformat.info/info/unicode/char/a5/index.htm

-Tim




-Original Message-
From: 4D_Tech <4d_tech-boun...@lists.4d.com> On Behalf Of Timothy Penner via 
4D_Tech
Sent: Wednesday, December 19, 2018 3:13 PM
To: 4D iNug Technical <4d_tech@lists.4d.com>
Cc: Timothy Penner 
Subject: RE: Understanding Unicode Characters

https://www.fileformat.info/info/unicode/char/2022/index.htm

HTML Entity (decimal)
HTML Entity (hex)
HTML Entity (named)
How to type in Microsoft WindowsAlt +2022
UTF-8 (hex)0xE2 0x80 0xA2 (e280a2)
UTF-8 (binary)11100010:1000:10100010
UTF-16 (hex)0x2022 (2022)
UTF-16 (decimal)8,226
UTF-32 (hex)0x2022 (2022)
UTF-32 (decimal)8,226
C/C++/Java source code"\u2022"
Python source codeu"\u2022"







-Original Message-
From: 4D_Tech <4d_tech-boun...@lists.4d.com> On Behalf Of Robert ListMail via 
4D_Tech
Sent: Wednesday, December 19, 2018 3:08 PM
To: 4D iNug Tech <4d_tech@lists.4d.com>
Cc: Robert ListMail 
Subject: Understanding Unicode Characters

In a galaxy far far away, we commonly used option-8 on the Mac to get a bullet 
glyph or symbol. At some point while converting databases from Mac to Windows 
this was changed to Char(165). Now, I see that Char(165), in a converted 
database, gives me the Yen sign. I’ve stumbled on the fact that Char(8226) 
gives me the bullet symbol in Windows but I don’t understand it.

So Option-8 on the Mac and Char(8226) via 4D seem to give me the same 
character, where Bbedit reports the character as:

Hex: E2 80 A2
Decimal: 226 128 162
Unicode: 2022

Why is the decimal value of 8226 not mentioned in the data above? Is there a 4d 
command that takes unicode values as a parameter, such that I could input 2022 
and get the bullet glyph?

Also when you look at the wiki referenced by the 4D docs 
(https://en.wikipedia.org/wiki/List_of_Unicode_characters 
<https://en.wikipedia.org/wiki/List_of_Unicode_characters>) and refer to the 
bullet, you get “U+2022” and what seems like a decimal value of 916. Where is 
the 916 coming from and why is the unicode value written as “U+2022”, do you 
ever have to type “U+”?

Sorry for such a fundamental question, I guess it’s time to learn more about 
character sets.

Thanks,

Robert
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**

RE: Understanding Unicode Characters

2018-12-19 Thread Timothy Penner via 4D_Tech
https://www.fileformat.info/info/unicode/char/2022/index.htm

HTML Entity (decimal)
HTML Entity (hex)
HTML Entity (named)
How to type in Microsoft WindowsAlt +2022
UTF-8 (hex)0xE2 0x80 0xA2 (e280a2)
UTF-8 (binary)11100010:1000:10100010
UTF-16 (hex)0x2022 (2022)
UTF-16 (decimal)8,226
UTF-32 (hex)0x2022 (2022)
UTF-32 (decimal)8,226
C/C++/Java source code"\u2022"
Python source codeu"\u2022"







-Original Message-
From: 4D_Tech <4d_tech-boun...@lists.4d.com> On Behalf Of Robert ListMail via 
4D_Tech
Sent: Wednesday, December 19, 2018 3:08 PM
To: 4D iNug Tech <4d_tech@lists.4d.com>
Cc: Robert ListMail 
Subject: Understanding Unicode Characters

In a galaxy far far away, we commonly used option-8 on the Mac to get a bullet 
glyph or symbol. At some point while converting databases from Mac to Windows 
this was changed to Char(165). Now, I see that Char(165), in a converted 
database, gives me the Yen sign. I’ve stumbled on the fact that Char(8226) 
gives me the bullet symbol in Windows but I don’t understand it.

So Option-8 on the Mac and Char(8226) via 4D seem to give me the same 
character, where Bbedit reports the character as:

Hex: E2 80 A2
Decimal: 226 128 162
Unicode: 2022

Why is the decimal value of 8226 not mentioned in the data above? Is there a 4d 
command that takes unicode values as a parameter, such that I could input 2022 
and get the bullet glyph?

Also when you look at the wiki referenced by the 4D docs 
(https://en.wikipedia.org/wiki/List_of_Unicode_characters 
) and refer to the 
bullet, you get “U+2022” and what seems like a decimal value of 916. Where is 
the 916 coming from and why is the unicode value written as “U+2022”, do you 
ever have to type “U+”?

Sorry for such a fundamental question, I guess it’s time to learn more about 
character sets.

Thanks,

Robert
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**
**
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:4d_tech-unsubscr...@lists.4d.com
**