Xah Emacs Blog
You, put $5 in my patreon. https://www.patreon.com/xahlee
for keyboard fans, goto Xah keyboard Blog
Elisp: provide, require, features (minor update)
2019-01-16 todo. work in progress Emacs Lisp Script Examples
2019-01-16 todo. work in progress Elisp: Twitterfy code rewritten. still experimenting.
create or add
(require 'uniquify) to emacs init page.
remove and link it from Xah Emacs Blog Archive 2011-07
2019-01-16 todo. to post
org mode Topic
reviewed and updated
2019-01-16 todo. consider add properties to my org markup tutorial Emacs: Org Mode Markup Cheatsheet
** travel :day1: :PROPERTIES: :ORDERED: t :ID: 6nSTF :OWNER: Lee :END:
those enclosed by colons are properties. they are key value pairs, associated with the heading. see https://orgmode.org/manual/Properties-and-Columns.html#Properties-and-Columns
also add tags. e.g.
** mom's birthday :family:
also, maybe add timestamp format
also, agenda priority mark
*** TODO [#A] Tim
code update. now, on url that contains a parenthesis, will work.
incomprehensible doc/spec from official big corps/orgs
now, having studied the whole, the org APIs are pretty good. My mistake was finding and reading that org-element.el doc, which lead to complete incomprehension.
when coding for work, often, you got 10 protocols/lang/names you need to understand. For each, you found 10 docs and tutorials. First you need to decide which to read. if you lucky, your 1st read is a good one. if unlucky, hours or days of bad taste in your mouth.
if official doc/tutorial are good, we don't have this problem. Often, the official ones are lousy. When the lang/protocol is from big corps, such as html/css/js/unix/tcp protocols, the official doc/spec e.g. from W3C ECMA RFC are usually entirely worthless.
doc/spec from W3C ECMA RFC etc are lousy not because they need to be formal or encompassing or academic computer science jargons. Rather, they are incomprehensible due to politics, commercialism, corp/org interests.
See also: doc by dummies
now, the tutorial is complete. Read it in 10 min, and you can write elisp code that extract tree structure and output in another format, such as json or graphviz DOT.
#emacs read the org mode syntax spec https://orgmode.org/worg/dev/org-syntax.html
it's the worst syntax spec ever written on this earth.
badly written, sloppy. it's no where like an actually syntax spec. Rather, it tries to describe the syntax to humans. but even at that, it's so badly written, ambiguous. not surprising, e.g. markdown the original version don't have syntax spec neither.
for example, i have a hard time understand its “greater element”, “element”, “object”. and its mention of “context free”, is questionable, rather completely bogus or misleading.
org-element.el, Parser for Org Syntax is written by Nicolas Goaziou. Don't know who he is, but great job. it's 6k lines. The org mode syntax spec, don't know who wrote it, very bad.
#emacs org mode. this is odd. i thought the maintainer is Bastien Guerry https://bzg.fr/ for over 10 years @bzg2 this is odd. i thought the maintainer is Bastien Guerry https://bzg.fr/ for over 10 years
reviewed and updated.
Elisp: Property List (updated)
Elisp: Symbol Property List (updated)
Elisp: Write grep (major update)
and See also, major updates
there's this package https://github.com/theodorewiles/org-mind-map , pretty lousy. errors. doesn't work.
See also: Intro to Mindmap, Gantt Chart, Graphviz
currently, looking at sacha's code for extracting org mode file's tree structure into elisp. http://pages.sachachua.com/evil-plans/ bottom. sweet
are there emacs written in Common Lisp or Scheme Lisp?
yeah. here's some old articles. 10 years old.
xah emacs tutorial good
been working on my emacs/elisp tutorial in the past days. spent several hours a day, to review, and organize the pages. Today, this index about emacs key related topic, is much updated and reviewed.
i work on getting the emacs tutorial update sent to all buyers today.
xah emacs tutorial, new nav boxes and other updates
new nav boxes at Emacs Lisp Command Examples
and also added lots of other nav boxes at Practical Emacs Tutorial and other pages.
these nav boxes group pages of samiliar topic. They help organization.
also, updated Xah Emacs Sitemap
now 741 html pages.
there are lots more to do. As usual, i update the site and articles in a continuous style daily thru-out the years.
xah emacs talk show 2019-01-07 xah-html-mode vs org mode
- writing raw html
- Japanese writing system
emacs talk: vim golf delete lines
new video. emacs talk: vim golf delete lines https://www.youtube.com/watch?v=XHfVYRkxxLQ am experimenting with video style. e.g. professional, focused, comedic, community building, nutjob as myself, heroic hacker, etc. lol. and lol style.
Emacs in Microsoft Windows FAQ minor update
now, the Practical Emacs Tutorial has much better table of contents. Each topic grouped into a box. still working on it.
emacs talk show. workflow. command log mode, working with raw html
#emacs talk show. my video skill improved. still need to cut verbosity.
randomish topic discussed:
- command log mode
- add html nav bar
- categorization problem
- 15:50 undo hell
- using xah-fly-keys.el and xah-html-mode.el
subscribe to my YouTube channel
video. The most efficient ways to switch window/app in linux, Mac, Windows.
- Set Key to Switch to emacs/terminal/browser How to Set Key to Switch to Browser
- Mac autoclick Mac: Hover to Switch Window
- Linux hover raise window Linux: Mouse Hover to Auto-Raise Window
- Linux autoclick Linux: Mouse Hover-Click
- ban Key Chords Banish Key Chords
- Why Function Keys Are Useful Why Function Keys Are Useful
comment on my YouTube or discuss on reddit https://www.reddit.com/r/emacs/comments/ach96l/most_efficient_ways_to_switch_windowapp/
a lot people like the style of type somethig to search. I think it began with the Mac app QuickSilver back around 2004. Then, it spread to MacOS, Microsoft Windows, Linux, and emacs (helm. was known as “everything”)
personally i don't like that workflow. (and actually don't use it in any OS nor in emacs)
with respect to switching windows/app, note that, the type something method is far less efficient. With function keys, it's just 1 key stroke. With the text search method, first a key combo to bring up the search box, then 3 or more letters. Though, it has advantage of being useful in general and no need setup. But i think its still better to set function keys. Can have both.
new organization block
Emacs Text Transform Under Cursor
- Toggle Letter Case
- Title Case
- Upcase Sentences
- Cycle Space Hyphen Underscore
- Escape Quotes
- Quote Lines
- Spaces to New Lines
- Change Brackets/Quotes
- Remove Accent Marks
- Convert Straight/Curly Quotes
- Convert English/Chinese Punctuations
- Color Conversion (RGB, HSL, HSV)
- Decimal to Hexadecimal
- Replace Greek Letter Names to Unicode
- Twitterfy Text
- Toggle line wrap
- Clean White Space
whenever you see a block like that on my emacs tutorial site, that means, each page will have the same navigation block.
It's for grouping purposes. I have written many commands over the years, many pages it's hard to categorize. A page can be under elisp tutorial section, or be under html helpers, or under text transformation section, etc. So, this grouping helps. A page may have multiple groupings.
by the way, categorization has always been a major prolem. there's duodecimal system, library of congress system, encyclopedia britannica system. In general, things are not a tree. But rather, complex graph of connections. (by the way, this also means, Object Oriented Programing is idiotic.) there is also keyword taxonomy. by the way, Wikipedia has several articles about this i've checked regularly since 10 years ago.
on a different topic, i haven't sent out emacs tutorial update yet. it's on my todo. sorry about that.
Elisp: Chinese Character Reference Linkify (code update)
xah-find-replace-text to the rescue
a Chinese character etymology reference site's domain changed. #emacs to the rescue. 564 changes.
(xah-find-replace-text "http://www.chineseetymology.org/CharacterEtymology.aspx?submitButton1=Etymology&characterInput=" "http://hanziyuan.net/#" "/Users/xah/web/" "\\.html$" t t t t)
Mac processing video .mov .mp4 YouTube slow
here's my emacs videos. i haven't looked into what's in .mov format, but it's about 9 times size of mp4. (by the way, webm is even smaller). everytime you convert to mp4, all cpu ramp up, takes 20 min or so to process 1 video. Then, you have to upload to youtube, another 20 min.
usually i write in emacs, copy, switch to browser, paste. All copy past select all switch are done with single key strokes. Actually, switching is mostly done with mouse hover auto-click. (partly due to lack of physical F keys in past 4 years) Want me to do a video to demo? that'd be good topic.
in 2018 i met few new emacs friends. Happy 2019 to
- Ag https://twitter.com/iLemming
- George Jones https://twitter.com/eludom
- Erik Anderson https://twitter.com/ebanders
- Scott Bilik https://twitter.com/sbilik
- Tim Chambers https://twitter.com/tbc0
hope a great emacs road in 2019.
emacs video hangout
am going to work in #emacs. come in to say hi, chat. https://hangouts.google.com/call/vk5h4A08VADHMgD-AEOLAEEE
emacs video, demo of image scale/crop/convert jpg/png commands
Best Unicode Fonts for Programer (minor update)
emacs lisp processing files
changing all Wikipedia links to https. #Emacs xah-find.el Emacs: xah-find.el, Find Replace in Pure Elisp comes to the rescue.
the page with the most change is Writer's Words Writer's Words, More 188 Wikipedia links
i learned about gumroad, a site to control and make money for creators https://gumroad.com/
via sachachua http://sachachua.com/
todo 2018-12-27, YouTube , xah-fly-keys modeline spacemacs
2018-12-26 todo put my YouTube vids on site https://www.youtube.com/user/polyglut/videos
2018-12-26 need to look at the modeline for spacemacs https://www.reddit.com/r/xahflykeys/comments/a7qczh/xah_fly_keys_ses_and_input_method_problems/
random number algorithm in emacs
i wonder what algorithm emacs lisp (random) use. i bet it's a bad linear congruential generator of 80s. someone prove me wrong. (am on Mac, don't have access to linux now. ... maybe i should lookup the repo on the web)
see random number
Elisp: Read/Write File
new page on its own.
Elisp: Buffer Functions
code update. now works with macOS
Manuals is a thing of the past
Manuals is a thing of the past. They are replaced by intuitive UI design, with on-the-fly tips or inline tips or web search based answers.
Most major software stopped printing manual since y2k. And no manual at all since 2010s, with onset of web app phone app software.
emacs fill/unfill rant
if one just want simple solution, it's here
Emacs: Hard Wrap Lines Emacs: Hard Wrap Lines
you can see here on stackoverflow 2011, Steve Purcell answered it with link to my site, and said he made it into a package. https://stackoverflow.com/questions/6707758/inverse-of-m-q-an-unfill-paragraph-function
(by the way Steve Purcell is a very nice guy, runs MELPA, and a better coder than me.)
there are earlier answers of the same question on stackoverflow using my code. you can tell by the magic number i used
i've since removed it. people complain that it should be
of course, am not the first one who wrote unfill. I remember seeing it on emacswiki.org , and elsewhere before.
The new one:
Emacs: Toggle Line Wrap Emacs: Toggle Line Wrap
does do better, because it toggles.
and the other version:
Emacs: Reformat Lines for Source Code Emacs: Reformat Lines for Source Code
is good because it can be reliably used for source code that are so called Whitespace Insignificant programing languages. [see What Does it Mean When a Programing Language Claims “Whitespace is Insignificant”?]
Dear SpacemacsMasterRace, thanks for reading my site though. :D seriousness aside.
what am i supposed to do? get inline and package stuff into a lunchbox and get rich quick?
well, there is more to it. emacs should have unfill builtin. it was a major criticism and frequently asked questions since at least 20 years ago. (i vaguely recall something like that happened in recent years. i did a quick apropos but apparently it's not there. Perhaps it was in some package, maybe in org mode.)
and the terminology should be changed. It's not fill/unfill bananas, it's hard wrap/unwrap. This touches on linguistics and communication efficiency, the art and science of jargons.
and, programers should be ban'd from this fill thing. The tradition of “truncating lines”, came from punch cards, and the damage was championed by unix geeks (note: not lisp geeks. unix geeks and lisp geeks were at war). and i have one thousand articles about it.
down the rabbit hole. am hopeless.
See also: Emacs: narrow-to-defun, eval-defun, bug
xah-fly-keys issue on reddit SES and Input Method problems, Mode-Line Config, TTY Caps Lock → Home Key.
Why Emacs Keys are Painful (updated old screenshots)
Elisp: Get Dired Marked File List (on its own page)
update code. Now put cursor at the end when command is done.
actually, just reverted it back. undecided
Emacs and RSI, Charlie Stross
got this Ultimate Hacking Keyboard
Just did a unboxing video, and already configured it to use with xah-fly-keys. Been using it for a day now. Going to update that page in the coming weeks.
emacs, RSI, nomads and monads
comes the day, someone heard of me because their dad told them. A living legend!
Emacs: 1 Key for M-x (on its own page)
Emacs: Use Alias for Fast M-x (updated)
on xah-fly-keys vs evil, chinese
an online friend, comment on xah-fly-keys vs evil
[xah-fly-keys 使用总结 By Pengpengxp. At https://pengpengxp.github.io/emacs/summary_of_xah_fly_keys.html ]
Thanks a lot to many people this year using and supporting Emacs: Xah Fly Keys 谢谢大家支持
latest version of xah emacs tutorial
sorry guys, i haven't send it out the update yet. Will do in next couple of days.
#emacs. integration of xah-fly-keys with spacemacs
i hope it gets in. Am going to spend some time with spacemacs and see if i can help in anyway.
from last year, now on its own page
Elisp: Print, Output. updated.
Emacs: xah-find.el, Find Replace in Pure Elisp updated. added back printing a “done” at the end.
xah-html-url-linkify now grabs url or filepath instead of line.
also updated in Emacs: Xah HTML Mode