all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* the tangled web of org-cite, selectrum, completing-read, ...
@ 2021-10-19 16:30 Eric S Fraga
  2021-10-19 17:23 ` Bruce D'Arcus
  2021-10-19 17:42 ` Nicolas Goaziou
  0 siblings, 2 replies; 10+ messages in thread
From: Eric S Fraga @ 2021-10-19 16:30 UTC (permalink / raw)
  To: Emacs Org mode mailing list

[-- Attachment #1: Type: text/plain, Size: 1241 bytes --]

Hello all,

TL;DR: how can I format the suggestions listed by selectrum when I ask
to insert a citation with org-cite-insert?

Longer version: I use selectrum a my completion engine together with
marginalia.  This works very well for most selections I wish to
make.  However, for org-cite, the display has the author list truncated
(to 25 characters; screenshot image attached, assuming it doesn't get
removed by the mailing list server) and the search only appears to
consider the truncated text.  The result is that if I am looking for a
paper by an author (say Kitchin ;-)) who is not one of the first few
authors on a particular publication, I won't be able to find that
particular publication (sorry John).

I have no idea which bit of the tool chain does the
formatting/truncation or whether I can make the search ignore the
truncated information.  I hope somebody has some suggestions.  I started
looking at bibtex-completions, which does mention org-cite (at least in
the most recent version), but none of the configuration suggestions
seems to have any effect.

Any pointers welcome!

Thank you,
eric

-- 
: Eric S Fraga via Emacs 28.0.60, Org release_9.5-149-g781080
: Latest paper written in org: https://arxiv.org/abs/2106.05096

[-- Attachment #2: screendump-20211019172509.png --]
[-- Type: image/png, Size: 95056 bytes --]

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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-19 16:30 the tangled web of org-cite, selectrum, completing-read, Eric S Fraga
@ 2021-10-19 17:23 ` Bruce D'Arcus
  2021-10-19 17:42 ` Nicolas Goaziou
  1 sibling, 0 replies; 10+ messages in thread
From: Bruce D'Arcus @ 2021-10-19 17:23 UTC (permalink / raw)
  To: Org Mode List

Eric - since you're using selectrum, any reason why not just use
oc-bibtex-actions?

Performance should be better, and it has a template system like
bibtex-completion.

On Tue, Oct 19, 2021 at 1:18 PM Eric S Fraga <e.fraga@ucl.ac.uk> wrote:
>
> Hello all,
>
> TL;DR: how can I format the suggestions listed by selectrum when I ask
> to insert a citation with org-cite-insert?
>
> Longer version: I use selectrum a my completion engine together with
> marginalia.  This works very well for most selections I wish to
> make.  However, for org-cite, the display has the author list truncated
> (to 25 characters; screenshot image attached, assuming it doesn't get
> removed by the mailing list server) and the search only appears to
> consider the truncated text.  The result is that if I am looking for a
> paper by an author (say Kitchin ;-)) who is not one of the first few
> authors on a particular publication, I won't be able to find that
> particular publication (sorry John).
>
> I have no idea which bit of the tool chain does the
> formatting/truncation or whether I can make the search ignore the
> truncated information.  I hope somebody has some suggestions.  I started
> looking at bibtex-completions, which does mention org-cite (at least in
> the most recent version), but none of the configuration suggestions
> seems to have any effect.
>
> Any pointers welcome!
>
> Thank you,
> eric
>
> --
> : Eric S Fraga via Emacs 28.0.60, Org release_9.5-149-g781080
> : Latest paper written in org: https://arxiv.org/abs/2106.05096


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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-19 16:30 the tangled web of org-cite, selectrum, completing-read, Eric S Fraga
  2021-10-19 17:23 ` Bruce D'Arcus
@ 2021-10-19 17:42 ` Nicolas Goaziou
  2021-10-19 19:54   ` Eric S Fraga
  1 sibling, 1 reply; 10+ messages in thread
From: Nicolas Goaziou @ 2021-10-19 17:42 UTC (permalink / raw)
  To: Org Mode List

Hello,

Eric S Fraga <e.fraga@ucl.ac.uk> writes:

> TL;DR: how can I format the suggestions listed by selectrum when I ask
> to insert a citation with org-cite-insert?
>
> Longer version: I use selectrum a my completion engine together with
> marginalia.  This works very well for most selections I wish to
> make.  However, for org-cite, the display has the author list truncated
> (to 25 characters; screenshot image attached, assuming it doesn't get
> removed by the mailing list server)

You can set `org-cite-basic-author-column-end' to a higher value.

> and the search only appears to
> consider the truncated text.  The result is that if I am looking for a
> paper by an author (say Kitchin ;-)) who is not one of the first few
> authors on a particular publication, I won't be able to find that
> particular publication (sorry John).
>
> I have no idea which bit of the tool chain does the
> formatting/truncation or whether I can make the search ignore the
> truncated information.

You are using the `basic' back-end for insertion. You may want to use
something else by setting `org-cite-insert-processor' to an appropriate
value, e.g., `oc-bibtex-actions'.

I hoped it would also be possible to set it to something like `org-ref'
or some such, but it doesn't seem it will happen.

Regards,
-- 
Nicolas Goaziou


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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-19 17:42 ` Nicolas Goaziou
@ 2021-10-19 19:54   ` Eric S Fraga
  2021-10-19 20:02     ` Bruce D'Arcus
  2021-10-19 20:04     ` Nicolas Goaziou
  0 siblings, 2 replies; 10+ messages in thread
From: Eric S Fraga @ 2021-10-19 19:54 UTC (permalink / raw)
  To: Nicolas Goaziou, Bruce D'Arcus; +Cc: Org Mode List

Nicolas & Bruce,

thank you for the suggestions.

> You can set `org-cite-basic-author-column-end' to a higher value.

This alone made no difference but ...

From Bruce:
> Eric - since you're using selectrum, any reason why not just use
> oc-bibtex-actions?

From Nicolas:
> You are using the `basic' back-end for insertion. You may want to use
> something else by setting `org-cite-insert-processor' to an appropriate
> value, e.g., `oc-bibtex-actions'.

I didn't know about oc-bibtex-actions; now I do!  So I did this, which
did not work immediately due to some errors; in particular,
=parsebib-parse= did not exist as I had an old version installed.

For the record, in the end, I needed to do the following:

  1. set =org-cite-basic-author-column= to a larger number
  2. install =embark=
  3. update and load =parsebib=
  4. load =oc-bibtex-actions=
  5. set =org-cite-insert-processor= to ='oc-bibtex-actions=

Now =org-cite-insert= works like a charm!  I had been planning on trying
out embark in due course; now I have no excuse to play with it sooner
than expected.

Thank you both.
-- 
: Eric S Fraga via Emacs 28.0.60, Org release_9.5-149-g781080
: Latest paper written in org: https://arxiv.org/abs/2106.05096


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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-19 19:54   ` Eric S Fraga
@ 2021-10-19 20:02     ` Bruce D'Arcus
  2021-10-19 20:07       ` Eric S Fraga
  2021-10-19 20:04     ` Nicolas Goaziou
  1 sibling, 1 reply; 10+ messages in thread
From: Bruce D'Arcus @ 2021-10-19 20:02 UTC (permalink / raw)
  To: Org Mode List; +Cc: Nicolas Goaziou

[-- Attachment #1: Type: text/plain, Size: 1565 bytes --]

The cool thing about embark-act in this context is it provides actions both
in the minibuffer and in the buffer at point (in this case, when on a
citation).

So it's like merging ivy-actions and a hydra.


On Tue, Oct 19, 2021, 3:54 PM Eric S Fraga <e.fraga@ucl.ac.uk> wrote:

> Nicolas & Bruce,
>
> thank you for the suggestions.
>
> > You can set `org-cite-basic-author-column-end' to a higher value.
>
> This alone made no difference but ...
>
> From Bruce:
> > Eric - since you're using selectrum, any reason why not just use
> > oc-bibtex-actions?
>
> From Nicolas:
> > You are using the `basic' back-end for insertion. You may want to use
> > something else by setting `org-cite-insert-processor' to an appropriate
> > value, e.g., `oc-bibtex-actions'.
>
> I didn't know about oc-bibtex-actions; now I do!  So I did this, which
> did not work immediately due to some errors; in particular,
> =parsebib-parse= did not exist as I had an old version installed.
>
> For the record, in the end, I needed to do the following:
>
>   1. set =org-cite-basic-author-column= to a larger number
>   2. install =embark=
>   3. update and load =parsebib=
>   4. load =oc-bibtex-actions=
>   5. set =org-cite-insert-processor= to ='oc-bibtex-actions=
>
> Now =org-cite-insert= works like a charm!  I had been planning on trying
> out embark in due course; now I have no excuse to play with it sooner
> than expected.
>
> Thank you both.
> --
> : Eric S Fraga via Emacs 28.0.60, Org release_9.5-149-g781080
> : Latest paper written in org: https://arxiv.org/abs/2106.05096
>

[-- Attachment #2: Type: text/html, Size: 2156 bytes --]

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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-19 19:54   ` Eric S Fraga
  2021-10-19 20:02     ` Bruce D'Arcus
@ 2021-10-19 20:04     ` Nicolas Goaziou
  2021-10-19 20:08       ` Eric S Fraga
  1 sibling, 1 reply; 10+ messages in thread
From: Nicolas Goaziou @ 2021-10-19 20:04 UTC (permalink / raw)
  To: Org Mode List

Eric S Fraga <e.fraga@ucl.ac.uk> writes:

> For the record, in the end, I needed to do the following:
>
>   1. set =org-cite-basic-author-column= to a larger number

You can ignore this step, which is useful (but is not as you report)
only when using `basic' insert processor. Here, you're using a different
insert processor.

Regards,


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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-19 20:02     ` Bruce D'Arcus
@ 2021-10-19 20:07       ` Eric S Fraga
  0 siblings, 0 replies; 10+ messages in thread
From: Eric S Fraga @ 2021-10-19 20:07 UTC (permalink / raw)
  To: Bruce D'Arcus; +Cc: Org Mode List, Nicolas Goaziou

On Tuesday, 19 Oct 2021 at 16:02, Bruce D'Arcus wrote:
> The cool thing about embark-act in this context is it provides actions
> both in the minibuffer and in the buffer at point (in this case, when
> on a citation).
>
> So it's like merging ivy-actions and a hydra.

This is roughly what I thought embark would provide.  I look forward to
trying it out more carefully later this week.

Thanks again,
eric

-- 
: Eric S Fraga via Emacs 28.0.60, Org release_9.5-149-g781080
: Latest paper written in org: https://arxiv.org/abs/2106.05096


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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-19 20:04     ` Nicolas Goaziou
@ 2021-10-19 20:08       ` Eric S Fraga
  2021-10-20 18:43         ` Bruce D'Arcus
  0 siblings, 1 reply; 10+ messages in thread
From: Eric S Fraga @ 2021-10-19 20:08 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: Org Mode List

On Tuesday, 19 Oct 2021 at 22:04, Nicolas Goaziou wrote:
>>   1. set =org-cite-basic-author-column= to a larger number
>
> You can ignore this step, which is useful (but is not as you report)
> only when using `basic' insert processor. Here, you're using a different
> insert processor.

yes, I kind of thought this might be the case in the end (but wasn't
sure)!  As I don't need to use the basic insert processor any longer, I
have deleted this line from my configuration.

Thanks again,
eric

-- 
: Eric S Fraga via Emacs 28.0.60, Org release_9.5-149-g781080
: Latest paper written in org: https://arxiv.org/abs/2106.05096


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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-19 20:08       ` Eric S Fraga
@ 2021-10-20 18:43         ` Bruce D'Arcus
  2021-10-21  7:00           ` Eric S Fraga
  0 siblings, 1 reply; 10+ messages in thread
From: Bruce D'Arcus @ 2021-10-20 18:43 UTC (permalink / raw)
  To: Org Mode List; +Cc: Nicolas Goaziou

On Tue, Oct 19, 2021 at 4:09 PM Eric S Fraga <e.fraga@ucl.ac.uk> wrote:
>
> On Tuesday, 19 Oct 2021 at 22:04, Nicolas Goaziou wrote:
> >>   1. set =org-cite-basic-author-column= to a larger number
> >
> > You can ignore this step, which is useful (but is not as you report)
> > only when using `basic' insert processor. Here, you're using a different
> > insert processor.
>
> yes, I kind of thought this might be the case in the end (but wasn't
> sure)!  As I don't need to use the basic insert processor any longer, I
> have deleted this line from my configuration.

BTW, per the bibtex-actions README, there are a few other small
packages you want to install for the best experience.

https://github.com/bdarcus/bibtex-actions#installation

For example, consult, in addition to all the convenience commands it
offers, also includes consult-completing-read-multiple, which replaces
default completing-read-multiple with a UI that is much better suited
to these long candidate strings.

Bruce


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

* Re: the tangled web of org-cite, selectrum, completing-read, ...
  2021-10-20 18:43         ` Bruce D'Arcus
@ 2021-10-21  7:00           ` Eric S Fraga
  0 siblings, 0 replies; 10+ messages in thread
From: Eric S Fraga @ 2021-10-21  7:00 UTC (permalink / raw)
  To: Bruce D'Arcus; +Cc: Org Mode List, Nicolas Goaziou

On Wednesday, 20 Oct 2021 at 14:43, Bruce D'Arcus wrote:
> BTW, per the bibtex-actions README, there are a few other small
> packages you want to install for the best experience.

Agreed.  I actually had all of these bar embark installed already.

thank you,
eric

-- 
: Eric S Fraga via Emacs 28.0.60, Org release_9.5-149-g781080
: Latest paper written in org: https://arxiv.org/abs/2106.05096


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

end of thread, other threads:[~2021-10-21  7:02 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-10-19 16:30 the tangled web of org-cite, selectrum, completing-read, Eric S Fraga
2021-10-19 17:23 ` Bruce D'Arcus
2021-10-19 17:42 ` Nicolas Goaziou
2021-10-19 19:54   ` Eric S Fraga
2021-10-19 20:02     ` Bruce D'Arcus
2021-10-19 20:07       ` Eric S Fraga
2021-10-19 20:04     ` Nicolas Goaziou
2021-10-19 20:08       ` Eric S Fraga
2021-10-20 18:43         ` Bruce D'Arcus
2021-10-21  7:00           ` Eric S Fraga

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.