edbrowse-dev - development list for edbrowse
 help / color / mirror / Atom feed
* [Edbrowse-dev] emojis and other chars
@ 2016-01-28  6:26 Karl Dahlke
  2016-01-28  8:49 ` Chris Brannon
  0 siblings, 1 reply; 4+ messages in thread
From: Karl Dahlke @ 2016-01-28  6:26 UTC (permalink / raw)
  To: Edbrowse-dev

Sometimes I want to paste an emoji into my text.
Or maybe even a greek letter or anything somewhat off the board.
If I'm writing html it's easy, I can put in γ or look up the unicode
for the emoji and write &#x....;
Sure no problem but I'm not always writing html.

While testing facebook I wanted to send some hearts to my wife in a message,
four hearts of different colors,
and I literally had to type in the &#x codes for all 4 of them,
as I am not an expert at converting unicode to utf8 on the fly.
Then I put <html> at the top, then browse,
then et to strip out all those internal codes,
(don't forget the et command if you do this!),
then join the lines together,
and then I had my text message with the hearts in place.
It works but wow.

Would it be worth writing a feature for input processing to do this?
Remember that ~xx inserts  a byte with that hex code.
That's part of input processing every time you type.
Even when setting the filename etc.
f a~c2~bdb
So perhaps ~[green heart] would look through a section of the config file
and find the unicode for the green heart and turn it into utf8 and paste it in.
Of course I would need to prime the config file with all the emojis
and other characters that I care about
but I already have such a file for my adapter.
The adapter uses it the other way around of course,
saying "green heart" when it runs into unicode 1f49a.

In a real dream world both edbrowse and the adapter could use the same file.
My adapter has the ability to include one file in another in its
configuration, so emojis could be their own file,
but edbrowse does not have an include directive.
And even if all that was done it would benefit me and no one else,
since only my adapter, and presumably edbrowse, would share the common format

x1f49a green heart

Other adapters would use some other syntax whence the file could not be shared.
I'm not going to set up these includes just to benefit me.

Well I can just maintain the unicode equivalents twice,
or write a perl script to keep things in sync or whatever.
Or maybe a combination of an edbrowse macro and a shell script could
take the line

green heart

and send it to a script that turns it back into the utf8 and paste that in instead,
but edbrowse doesn't have the ability to replace text generated by a shell command.

So I'm just bouncing ideas around for now.

by the way, my hearts went on Wendy's wall just fine, but I don't see them.
facebook does not show them to me on redisplay but others see them.  IDK
Twitter does everything right in this regard.

Karl Dahlke

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

* Re: [Edbrowse-dev] emojis and other chars
  2016-01-28  6:26 [Edbrowse-dev] emojis and other chars Karl Dahlke
@ 2016-01-28  8:49 ` Chris Brannon
  2016-01-28 11:18   ` Karl Dahlke
  0 siblings, 1 reply; 4+ messages in thread
From: Chris Brannon @ 2016-01-28  8:49 UTC (permalink / raw)
  To: Edbrowse-dev

There's another way to enter high unicodes.
Hold the alt key, and type out the character's decimal value on the
numeric keypad.  It's kind of cumbersome, since we usually use hex when
dealing with high unicode, but it works.

-- Chris

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

* [Edbrowse-dev]  emojis and other chars
  2016-01-28  8:49 ` Chris Brannon
@ 2016-01-28 11:18   ` Karl Dahlke
  2016-01-28 11:58     ` Chris Brannon
  0 siblings, 1 reply; 4+ messages in thread
From: Karl Dahlke @ 2016-01-28 11:18 UTC (permalink / raw)
  To: Edbrowse-dev

> Hold the alt key, and type out the character's decimal value

Yeah I thought something like that, but does that work on bsd? On Windows?
I wanted something that was easy (preferably hex) and also portable,
and could even work from within an edbrowse script etc.

Karl Dahlke

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

* Re: [Edbrowse-dev] emojis and other chars
  2016-01-28 11:18   ` Karl Dahlke
@ 2016-01-28 11:58     ` Chris Brannon
  0 siblings, 0 replies; 4+ messages in thread
From: Chris Brannon @ 2016-01-28 11:58 UTC (permalink / raw)
  To: Edbrowse-dev

Karl Dahlke <eklhad@comcast.net> writes:

> Yeah I thought something like that, but does that work on bsd? On Windows?
> I wanted something that was easy (preferably hex) and also portable,

Well I'm pretty sure it works on Windows.  I don't know about BSD.  It
definitely wouldn't work well on Mac, even if the OS happened to support
it, because Apple keyboards lack numpads.

-- Chris

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

end of thread, other threads:[~2016-01-28 11:58 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-28  6:26 [Edbrowse-dev] emojis and other chars Karl Dahlke
2016-01-28  8:49 ` Chris Brannon
2016-01-28 11:18   ` Karl Dahlke
2016-01-28 11:58     ` Chris Brannon

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 NNTP newsgroup(s).