Questions tagged [call-interactively]
12 questions
2
votes
3 answers
call write-file interactively with prompting
I have a function that creates a buffer, with a default file name, and would like the first user action for that buffer be a prompt to write the buffer to a file, allowing the user to change the default, but offering the default in the minibuffer…

user1404316
- 769
- 5
- 12
1
vote
0 answers
Calling load-theme with interactive input
I want to call load-theme within a function. Whilst it is supposed to give an interactive input using completing-read, just calling load-theme gives an error and the interactive input is not activated. What can I do to get the interactive…

Dilna
- 1,173
- 3
- 10
1
vote
1 answer
Call an interactive function and pass argument to it in elisp without user input
I am new to elisp and am trying to write an Elisp function that calls org-pandoc-export-to-html5-pdf-and-open.
org-pandoc-export-to-html5-pdf-and-open is an interactive function that will write to a file, and when called via M-x, it prompts the…

nonreligious
- 473
- 2
- 14
1
vote
1 answer
How to script a bookmark-jump call
I am trying to write a function which will perform a bookmark-jump but then reset the the bookmark line to the top of the screen. So far I have:
(defun foo ()
(interactive)
(bookmark-jump)
(evil-scroll-line-to-top nil)
)
…

user2567544
- 291
- 1
- 9
1
vote
2 answers
Problem with giving inputs to a function programmatically
Some programs take user inputs, for example by calling the interactive function `sunrise-sunset', two arguments are taken from the user. Assume that the inputs are 0.0098 and 51.4934 (these are longitude and latitude of Greenwich).
It would be…

Name
- 7,689
- 4
- 38
- 84
1
vote
1 answer
isearch-forward, call-interactively, and isearch-filter-predicate
Here are two use cases where I call isearch-forward with some filter predicate.
(let ((isearch-filter-predicate (lambda (a b) nil)))
(funcall 'isearch-forward))
(let ((isearch-filter-predicate (lambda (a b) nil)))
(call-interactively…

Michaël
- 314
- 1
- 10
0
votes
0 answers
ISO generic "call command interactively, interactively overriding global variables ..."
BRIEF: looking for an elisp package to make it easier and more to wrapperize calling interactive commands, temporarily overriding global variables as if by let.
---+ DETAIL:
ISO = In Search Of. I know how to write this - I have written many…

Krazy Glew
- 242
- 2
- 8
0
votes
0 answers
Why is the function call-interactively so slow when called from my init.el file?
I'm creating an Elisp function that basically copies the selected text to the clipboard and then it sends a signal to a TCP port that will trigger a TTS voice that reads aloud what's on the clipboard for me. The function I'm using is the…

raylight
- 217
- 8
0
votes
1 answer
How to call a interactive function with prompt from a lambda?
I have this little LaTeX helper function:
(defun my--insert-chord (chord)
"Prompt for a CHORD and insert it at point. TODO: make it agnostic to the package used."
(interactive "MChord: ")
(insert (concat "\\[" chord "]")))
that works like a…

Alessandro Bertulli
- 195
- 10
0
votes
0 answers
Call a function and all relevant hooks inside a function
I have a function consisting of 2 commands.
(defun my-function ()
(interactive)
(call-interactively 'run-python) ; <-- Something is not run after this line.
(call-interactively 'python-shell-send-buffer))
When executing…

Gradient
- 211
- 1
- 4
0
votes
0 answers
Why an error when calling a command in a specific buffer?
Q: why do I get errors when calling a command from a specific buffer, but not in any other buffer?
Scratch all of what I had previously said about
call-interactively (see strikethrough below for reference). It's not even remotely that.
I've done…

Dan
- 32,584
- 6
- 98
- 168
0
votes
1 answer
Call a function by its key (inside a script)
I have a tool that allows me to use the same key (shortcut) C-c C-f to call different functions. Actually I can choose different options (different functions) to pass to the LaTeX compiler, binding them to the shortcut C-c C-f.
Here's my tool (to…

Gabriele Nicolardi
- 1,199
- 8
- 17