Re: Website revamp?

2020-08-03 Thread TEC



Good to hear from you!

Eric S Fraga  writes: 


I do like the animated images in the features page!


Glad you like them! I recently converted the static images to SVGs 
with the help of someone using Emacs27 w/ Cairo, would be nice go 
do something like an animated SVG in the future, but that's for 
(much) later :P


I do wonder about 
the order of the topics within that page, e.g. working with 
source code, although powerful, is probably not the lead item 
for new users.  However, that's a minor point at this stage. 


Thanks for this feedback. I prioritised the source code blocks 
because:
a) my impression is that to Comp/Data Sci people, they are one of 
/the/ most 
   compelling features of Org-mode 
b) they're similar to elements people are familiar with (Jupyter 
   notebooks, R markdown), so the Comp/Data Sci segment of our 
   audience is already roughy familiar with part of their 
   capabilities 


I shifted the agenda/capture/clocking/etc. features down because
a) they semantically seem like they should go together b) having 
them near the top pushes down too many other features too much, 
IMO


Absolutely worth considering the order, please share any further 
thoughts you may have :)


More generally, can the column width for the text be a function 
of the window width and have images scaled so that they are not 
wider than the text column?  It should be possible to have 
mobile friendly without making the columns too narrow for full 
desktop use.  The fact that the images are much wider than the 
text makes the page look ugly, in my opinion. 


The column width already is. I just find long lines undesirable. 
50-80 characters is the standard in publishing for a reason.


To quote from /The Elements of Typographic Style/,
Anything from 45 to 75 characters is widely regarded as a 
satisfactory line length of line for a single-column page set in 
a serifed text face in a text size. The 66-character line 
(counting both letters and spaces) is widely regarded as ideal. 
For multiple-column work, a better average is 40 to 50 
characters. If the type is well set and printed, lines of 85 or 
90 characters will pose no problem in discontinuous texts, such 
as bibliographies, or, with generous leading, in footnotes. But 
even with generous leading, a line that averages more than 75 or 
So characters is likely to be too long for continuous reading. 


There's more to be said about line spacing and the reasons for 
this - if I recall correctly /A practical guide to typography/ 
(available online) goes over this.


I look forward to hearing any further comments you may have!

Timothy.



Re: Bug: Exporting internal link to special latex block [9.3.7 (9.3.7-14-gb2b587-elpa @ /home/lobo/.emacs.d/elpa/org-20200720/)]

2020-08-03 Thread Eric S Fraga
On Tuesday, 21 Jul 2020 at 15:52, Marco Falconi wrote:
> I am trying to export to html a labeled latex special block (a theorem
> environment,

[...]

> the link does not href to "#thm:mv" as expected, but to an auto-generated 
> label:

Confirmed with org from git a few minutes ago.  The link using an
auto-generated label would be fine if the label were the one for the
special block but it's not.

-- 
: Eric S Fraga via Emacs 28.0.50, Org release_9.3.7-682-geac255



Re: File local setting for export directory?

2020-08-03 Thread Loris Bennett
Hi Eric,

Eric Abrahamsen  writes:

> "Loris Bennett"  writes:
>
>> Hi,
>>
>> I want to export an org file to a pdf and have the pdf created in
>> subdirectory relative to the org file.
>>
>> What's the simplest way to set the export directory in a file local way?
>
> I suggested the attached diff a while ago, but no one seemed very
> interested. I think it might already do what you want.
>
>
> diff --git a/lisp/ox.el b/lisp/ox.el
> index 9cf62078a..77cafb20d 100644
> --- a/lisp/ox.el
> +++ b/lisp/ox.el
> @@ -6417,6 +6417,20 @@ Return file name as a string."
> "Output file: " pub-dir nil nil nil
> (lambda (n) (string= extension (file-name-extension n t))
>  extension))
> +  (pub-dir (or pub-dir
> +   (and subtreep (org-entry-get
> +  nil "EXPORT_PUB_DIR" 'selective))
> +   (org-with-point-at (point-min)
> + (catch :found
> +   (let ((case-fold-search t))
> + (while (re-search-forward
> + "^[ \t]*#\\+EXPORT_PUB_DIR:[ \t]+\\S-"
> + nil t)
> +   (let ((element (org-element-at-point)))
> + (when (eq 'keyword (org-element-type element))
> +   (throw :found
> +  (org-element-property
> +   :value element))
>(output-file
> ;; Build file name.  Enforce EXTENSION over whatever user
> ;; may have come up with.  PUB-DIR, if defined, always has
>

Thanks for the patch - it is exactly what I needed.

I'm surprised no-one was interested, although I suppose back then I was
probably also one of the uninterested :-)

I only have one org file from which I generate a number of graphics as
well a PDF which contains the graphics.  Don't many people do a lot more
of that kind of stuff and don't they want to exclude a directory with
generated files from, say, Git?

Any way, +1 for the patch, which I would like to see in Org.

Cheers,

Loris

-- 
This signature is currently under construction.



Re: Website revamp?

2020-08-03 Thread Eric S Fraga
On Monday,  3 Aug 2020 at 10:03, to...@tuxteam.de wrote:
> Emacs should run fine on PostmarketOS [1] [2]. Thus Org, too.

Emacs runs perfectly fine on Android via termux and org works as well (as does 
gnus!).

But the issue is the keyboard.

-- 
: Eric S Fraga via Emacs 28.0.50, Org release_9.3.7-682-geac255



Re: Website revamp?

2020-08-03 Thread Eric S Fraga
I do like the animated images in the features page!  I do wonder about
the order of the topics within that page, e.g. working with source code,
although powerful, is probably not the lead item for new
users.  However, that's a minor point at this stage.

More generally, can the column width for the text be a function of the
window width and have images scaled so that they are not wider than the
text column?  It should be possible to have mobile friendly without
making the columns too narrow for full desktop use.  The fact that the
images are much wider than the text makes the page look ugly, in my
opinion.

thank you,
eric

-- 
: Eric S Fraga via Emacs 28.0.50, Org release_9.3.7-682-geac255



Re: File local setting for export directory?

2020-08-03 Thread Nick Dokos
Russell Adams  writes:

> On Mon, Aug 03, 2020 at 04:15:22PM +0200, Loris Bennett wrote:
>> I want to export an org file to a pdf and have the pdf created in
>> subdirectory relative to the org file.
>>
>> What's the simplest way to set the export directory in a file local way?
>
> Can you just set your EXPORT_FILE_NAME  to include that directory?
>
> #+EXPORT_FILE_NAME: subdir/Thing.html
>
> You might need a FQPN. You'll have to test.
>

Unfortunately, this produces the tex file in the subdir, but the
xelatex/pdflatex process is still run in the current directory, with
`subdir/file.tex' as input file, so it produces the PDF in the current
directory.

I was wondering why Eric A. suggested a patch, but I guess this
is the reason (N.B. I haven't tried his patch).

-- 
Nick

"There are only two hard problems in computer science: cache
invalidation, naming things, and off-by-one errors." -Martin Fowler




Re: File local setting for export directory?

2020-08-03 Thread Eric Abrahamsen
"Loris Bennett"  writes:

> Hi,
>
> I want to export an org file to a pdf and have the pdf created in
> subdirectory relative to the org file.
>
> What's the simplest way to set the export directory in a file local way?

I suggested the attached diff a while ago, but no one seemed very
interested. I think it might already do what you want.


diff --git a/lisp/ox.el b/lisp/ox.el
index 9cf62078a..77cafb20d 100644
--- a/lisp/ox.el
+++ b/lisp/ox.el
@@ -6417,6 +6417,20 @@ Return file name as a string."
 	  "Output file: " pub-dir nil nil nil
 	  (lambda (n) (string= extension (file-name-extension n t))
 	   extension))
+	 (pub-dir (or pub-dir
+		  (and subtreep (org-entry-get
+ nil "EXPORT_PUB_DIR" 'selective))
+		  (org-with-point-at (point-min)
+			(catch :found
+			  (let ((case-fold-search t))
+			(while (re-search-forward
+"^[ \t]*#\\+EXPORT_PUB_DIR:[ \t]+\\S-"
+nil t)
+			  (let ((element (org-element-at-point)))
+(when (eq 'keyword (org-element-type element))
+  (throw :found
+	 (org-element-property
+	  :value element))
 	 (output-file
 	  ;; Build file name.  Enforce EXTENSION over whatever user
 	  ;; may have come up with.  PUB-DIR, if defined, always has


[Feature Request] More flexibility in org-speed-commands customization

2020-08-03 Thread Gustavo Barros

Hi All,

Org's speed keys are a very interesting feature to which I've long been 
attracted to.  And indeed, I've flirted with it a number of times in the 
past.  But every time I do so, I end up stepping back, because I get 
weary of fat fingering my documents.  The whole set of speed keys is 
more powerful than what I would wish.  I'd love to have speed keys for 
navigation and visibility, but I would also gladly refrain from these 
"too handy" editing keys.


As things stand, the speed keys are defined by combining 
`org-speed-commands-default', a defconst, and `org-speed-commands-user', 
a defcustom.  But the former already contains a large set of speed keys, 
including some quite powerful editing ones.  And it is thus hard to 
remove these keys.


Of course, it is possible.  We could shadow the same key in 
`org-speed-commands-user' to do nothing.  Or, though a defconst, 
`org-speed-commands-default' can be redefined after loading Org.  The 
first is clumsy, and renders the `org-speed-command-help' buffer quite 
confusing.  The second feels wrong (because it is).


I don't know if there is a strong reason to hard-code the set of keys in 
`org-speed-commands-default'.  But, if there isn't, could you consider 
(somehow) exposing the whole set of `org-speed-commands' to user 
customization?


Best,
Gustavo.



Re: File local setting for export directory?

2020-08-03 Thread Russell Adams
On Mon, Aug 03, 2020 at 04:15:22PM +0200, Loris Bennett wrote:
> I want to export an org file to a pdf and have the pdf created in
> subdirectory relative to the org file.
>
> What's the simplest way to set the export directory in a file local way?

Can you just set your EXPORT_FILE_NAME  to include that directory?

#+EXPORT_FILE_NAME: subdir/Thing.html

You might need a FQPN. You'll have to test.

--
Russell Adamsrlad...@adamsinfoserv.com

PGP Key ID: 0x1160DCB3   http://www.adamsinfoserv.com/

Fingerprint:1723 D8CA 4280 1EC9 557F  66E8 1154 E018 1160 DCB3



How create a hook before export ONLY to text

2020-08-03 Thread pineiden
Hi friends.

First time here, I have a couple of years working with org and i love it.
Now I have a problem.
I discovered the plantuml language to create nice charts, also I have minted 
configured to transform in latex to pdf.
But minted doesn't have the lexer so throws error.
I think, if there are a simple solution to do that.
A hook, maybe this:

org-export-before-parsing-hook

To parse or use 'sed' i don't know yet. To change the "#+BEGIN_SRC plantuml" to 
"#+BEGIN_SRC text" or similar.

So, what i need to know or do?
I know a little of lisp, i understand i have to:

- condition export to latex (only, because html is fine)
- if use plantuml change, if not not
- in latex has to create \begin{minted}[text] and not
\begin{minted}[plantuml]

Or, there are a general form to drop the minted on languages that not has 
lexer? Using emacs-org

Best regards!!

Sent with [ProtonMail](https://protonmail.com) Secure Email.

File local setting for export directory?

2020-08-03 Thread Loris Bennett
Hi,

I want to export an org file to a pdf and have the pdf created in
subdirectory relative to the org file.

What's the simplest way to set the export directory in a file local way?

Cheers,

Loris

-- 
This signature is currently under construction.




RE: Website revamp?

2020-08-03 Thread Gustav Wikström
Hi TEC,

Just wanted to add one datapoint here. I think this effort your putting down is 
commendable and deserves many +1's.

Reading about something ofc happen on devices other than where the software in 
the end is installed. Thus, I agree fully with what you write below!

Your draft is already a big improvement and I, for one, hope it can go into 
"release" as soon as possible. Even if it's not "perfect". Because nothing is, 
especially not regarding design, where facts are few and opinions are many.

Thank you.

/Gustav 

> -Original Message-
> From: Emacs-orgmode  On Behalf
> Of TEC
> Sent: den 3 augusti 2020 07:11
> To: Colin Baxter 
> Cc: emacs-orgmode@gnu.org
> Subject: Re: Website revamp?
> 
> 
> Colin Baxter  writes:
> 
> >> TEC   writes:
> >> - The site is now more mobile friendly, the navbar now has a
> >
> > Why? How many users are installing org-mode on their 'phones - smart
> > or otherwise?
> 
> Zero, I expect :P
> 
> However, I don't think that's the question we should be asking.
> Consider someone tweeting about org-mode, the question then is:
>   how many people use twitter on their phones?
> 
> Likewise, if someone wants to share a org-mode with a friend, and sends them
> a link - whether it be by email, sms, whatsapp, messenger, or telegram:
> what's the chance that they'll take a peek oh their phones?
> 
> Of course we don't exactly have any hard answers to these questions, but I'd
> wager the answer is enough to warrant a little bit of effort to make the
> mobile experience not-garbage. To see how orgmode.org currently appears, see
> https://i.imgur.com/XPFfBaB.png
> 
> IMO that's downright off-putting --- and I say that intending no criticism
> to Carsten or Bastien, in 2012 mobile design simple wasn't a priority.
> 
> Moreover, we can improve the mobile experience with no compromise to the
> desktop
> --- so why wouldn't we? :D
> 
> I hope this fleshes out my motivation for improving the mobile experience :)
> 
> Timothy.



Re: Website revamp?

2020-08-03 Thread TEC


Colin Baxter  writes: 

It seems to have the usual vertical monotone blocks, commonly 
seen in mobile sites. These may be necessary for the small 
screen but represent to me a retrograde development in web-site 
design.


Ah yes, the big banner on the index page. I think I can see your 
point of view --- the current index is far more informative. 
Ultimately though the decision to use a banner wasn't just 
triggered by mobile considerations, but a little re-think about 
the structure and purpose of the website.


As I see it, the desirable purpose of the 'main' pages is roughly 
as follows:
- index :: attention grabber - features :: capture interest, 
entice to try - releases :: see what's changed recently - install 
:: how to get started - documentation :: dig into the details - 
contribute :: encourage to give back to the project 

With those goals in mind, I see a large banner on the index 
declaring (effectively) that "org is great" as being in line with 
the above UX.


Of course, my criticism is unimportant since you are doing the 
hard work - not me.


Quite the contrary! If there's anything I want more of with this 
effort (appart from general help) it's criticism/feedback. As 
you've pointed out it's (effectively) just me working on this: so 
hearing other people's thoughts is emminently desirable. 

Would it be possible to have two sites: one for display on a 
desktop and another for mobile use? Perhaps not. 


Effectively, yes. You could have CSS as follows:

#+BEGIN_SRC css @media(min-width:851px) { 
   /* desktop style */ 
} @media(max-width:850px) { 
   /* mobile style */ 
} #+END_SRC


Good luck. 


Thanks :) I hope this can receive Bastien/Carsten's blessing and 
be used for the main site sooner rather than later.


All the best,

Timothy.



Re: Website revamp?

2020-08-03 Thread tomas
On Mon, Aug 03, 2020 at 01:11:24PM +0800, TEC wrote:
> 
> Colin Baxter  writes:
> 
> >> TEC   writes:
> >> - The site is now more mobile friendly, the navbar now has a
> >
> > Why? How many users are installing org-mode on their 'phones - smart or
> > otherwise? 
> 
> Zero, I expect :P

Emacs should run fine on PostmarketOS [1] [2]. Thus Org, too.

Cheers
[1] https://postmarketos.org/
[2] https://en.wikipedia.org/wiki/PostmarketOS
-- t


signature.asc
Description: Digital signature


Re: Website revamp?

2020-08-03 Thread Colin Baxter
Dear Timothy,

> TEC   writes:

- Snip --

> Of course we don't exactly have any hard answers to these
> questions, but I'd wager the answer is enough to warrant a little
> bit of effort to make the mobile experience not-garbage. To see
> how orgmode.org currently appears, see
> https://i.imgur.com/XPFfBaB.png

It seems to have the usual vertical monotone blocks, commonly seen in
mobile sites. These may be necessary for the small screen but represent
to me a retrograde development in web-site design. Of course, my
criticism is unimportant since you are doing the hard work - not me.

Would it be possible to have two sites: one for display on a desktop and
another for mobile use? Perhaps not.

Good luck.

Colin Baxter

-- 
Colin Baxter
URL: http://www.Colin-Baxter.com