Welcome Guest ( Log In | Register )

Outline · [ Standard ] · Linear+

 An idea of hobby project for the weekend, Anyone interested?

views
     
TSFlierMate4
post Feb 10 2023, 04:05 PM, updated 3y ago

Getting Started
**
Validating
90 posts

Joined: Jan 2023
Anyone interested in a hobby project for the weekend?

A simple Unicode code point converter.

Available font style to choose from:
» Click to show Spoiler - click again to hide... «


For example, user type the input and get the output:
QUOTE
This is something great!
Hopefully more is coming...


Output:
QUOTE
๐‘ป๐’‰๐’Š๐’” ๐’Š๐’” ๐’”๐’๐’Ž๐’†๐’•๐’‰๐’Š๐’๐’ˆ ๐’ˆ๐’“๐’†๐’‚๐’•!
๐‘ฏ๐’๐’‘๐’†๐’‡๐’–๐’๐’๐’š ๐’Ž๐’๐’“๐’† ๐’Š๐’” ๐’„๐’๐’Ž๐’Š๐’๐’ˆ...


You can choose only one Unicode font style to try.
Of course there are already many similar tool on the Internet, like : https://texteditor.com/font-converter/

But treat this as a practise and learning process if you don't already know.

I tried it successfully yesterday.

You can let user type in text box and convert to another text box, or take in a input text file, and write to another output text file.
I hope it is fun.
angch
post Feb 10 2023, 05:43 PM

On my way
****
Junior Member
636 posts

Joined: Jul 2006
user posted image

Done.

https://github.com/angch/discordbot/blob/ma.../unicodefont.go
TSFlierMate4
post Feb 10 2023, 05:57 PM

Getting Started
**
Validating
90 posts

Joined: Jan 2023
QUOTE(angch @ Feb 10 2023, 05:43 PM)
Oh wow, very clever of you, it is eye-opening you did it this way... unlike me, used the hard way to encode UTF-8. sweat.gif

Thumbs up for your discordbot, might join again to try it! laugh.gif
15cm
post Feb 10 2023, 09:51 PM

Casual
***
Junior Member
423 posts

Joined: Apr 2022
wait till my turn to use chatgpt i will get u your code pretty quickly

TSFlierMate4
post Feb 27 2023, 09:20 PM

Getting Started
**
Validating
90 posts

Joined: Jan 2023
QUOTE(15cm @ Feb 10 2023, 09:51 PM)
wait till my turn to use chatgpt i will get u your code pretty quickly
*
Your code for this simple Unicode conversion task is much welcomed.

------

In the mean time, I uploaded my program (with source code) to here, it reads from text content in input.txt, and convert to Unicode font in output.txt. Just double click unicode.exe will do. No command-line parameter required.

Enjoy! flex.gif

user posted image

This post has been edited by FlierMate4: Feb 28 2023, 02:46 AM


Attached File(s)
Attached File  unicode.zip ( 2.15k ) Number of downloads: 9
MatQuasar
post Oct 11 2023, 11:33 AM

Casual
***
Validating
329 posts

Joined: Jun 2023
I am thinking to create a Simplified <--> Traditional Chinese converter. As known, Chinese characters are 3-byte UTF-8, so I thought if there is a universal formula to convert between Simplified Chinese and Traditional Chinese..... But from my findings, it seems like the there is no such formula, maybe need to keep a long list? Can anyone advise, I want to manipulate UTF-8 myself.
angch
post Oct 11 2023, 12:51 PM

On my way
****
Junior Member
636 posts

Joined: Jul 2006
You'll end up needing custom mappings like this: https://github.com/BYVoid/OpenCC/tree/master/data/dictionary

Even the simpler implementation uses a hard coded dictionary mapping: https://github.com/siongui/gojianfan/blob/master/charsets.go

This post has been edited by angch: Oct 11 2023, 12:54 PM
MatQuasar
post Oct 11 2023, 01:23 PM

Casual
***
Validating
329 posts

Joined: Jun 2023
QUOTE(angch @ Oct 11 2023, 12:51 PM)
You'll end up needing custom mappings like this: https://github.com/BYVoid/OpenCC/tree/master/data/dictionary

Even the simpler implementation uses a hard coded dictionary mapping: https://github.com/siongui/gojianfan/blob/master/charsets.go
*
Thanks for the idea! Wah, the charsets.go has two very long lines!
MatQuasar
post Oct 25 2023, 08:16 PM

Casual
***
Validating
329 posts

Joined: Jun 2023
Found this code from China netizen, it supports validation of alphabet, digits and Chinese characters:
CODE
String regex = "^[a-zA-Z0-9\u4E00-\u9FA5]+$";


Looks like the \u4E00 to \u9FA5 must memorize, very useful in the future.
flashang
post Oct 25 2023, 10:24 PM

Casual
***
Junior Member
355 posts

Joined: Aug 2021


QUOTE(MatQuasar @ Oct 25 2023, 08:16 PM)
Found this code from China netizen, it supports validation of alphabet, digits and Chinese characters:
CODE
String regex = "^[a-zA-Z0-9\u4E00-\u9FA5]+$";


Looks like the \u4E00 to \u9FA5 must memorize, very useful in the future.
*
good to know the chinese characters range.
may need to find where can use it.

smile.gif



 

Change to:
| Lo-Fi Version
0.0255sec    0.94    6 queries    GZIP Disabled
Time is now: 23rd December 2025 - 08:40 AM