unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Introducing Master of Ceremonies, a package for presentations
@ 2024-12-03 16:01 Psionic K
  2024-12-04  2:45 ` Psionic K
  2024-12-04  9:16 ` Jean Louis
  0 siblings, 2 replies; 7+ messages in thread
From: Psionic K @ 2024-12-03 16:01 UTC (permalink / raw)
  To: Emacs developers; +Cc: Psionic K

I use this package for making videos and presentations.  It's almost
ready for archives.

https://github.com/positron-solutions/master-of-ceremonies
https://github.com/positron-solutions/master-of-ceremonies.git

`mc-focus' is one of the most useful commands.  Select a region, call
it, and that region will be displayed full screen with appropriate
scaling.  You can highlight multiple regions by selecting and using
the "l" key.  The "." key will activate a "subtle" cursor that goes
away after a short number of blinks to assist highlighting without
needing to hide the cursor all the time.  There is a magit-style
interface for learning the rest of the modal bindings, available under
"h".

The `mc-kill-ring-save` command will save an expression that can play
back this display, making it rather easy to step through sequences of
highlights.  This produces high quality illustrations of code that
line up well with explanation.  When combined with dslide (on non-GNU
ELPA and MELPA), the two packages can create effective presentations
about code that are missing almost nothing from dedicated presentation
software.

Many of the tools for accomplishing this were valuable as standalone
modes for presentation
- `mc-quiet-mode' suppresses messages
- `mc-subtle-cursor-mode' is great for using the cursor like a
transient laser pointer
- `mc-face-remap' will remap many faces from presets.  I use this to
tweak faces for  MC Focus screenshots.
- `mc-fixed-frame' sets to preset resolutions for recording videos and
corrects the size when minor actions like resizing buffer text change
the size of the frame

Bindings for built-in Emacs behaviors like hiding the mode line are
provided.  I only need to add support for modifying the transient to
allow myself to add keycast toggling.

These tools have been combined into a one-stop interface, `mc-dispatch'.

The core code for `mc-focus' acquired numerous behaviors I was using
personally and so the code is rather off.  It needs to be
re-architectured for smoothly supporting rectangle selection,
whitespace trimming, and playback.  I have experimented with
translating overlays from the source into the text properties of the
display.

Numerous things work in numerous settings, so I have made it available
ahead of publishing on package archives.  Emacs conf participants may
find it of use for some last minute embellishment.

PRs and issues will be attended to.



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

* Re: Introducing Master of Ceremonies, a package for presentations
  2024-12-03 16:01 Introducing Master of Ceremonies, a package for presentations Psionic K
@ 2024-12-04  2:45 ` Psionic K
  2024-12-04  3:01   ` Dmitry Gutov
  2024-12-04  9:16 ` Jean Louis
  1 sibling, 1 reply; 7+ messages in thread
From: Psionic K @ 2024-12-04  2:45 UTC (permalink / raw)
  To: Emacs developers, Philip Kaludercic; +Cc: Psionic K

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

I intend to submit Master of Ceremonies to Non-GNU ELPA.  I'm deciding what
changes are necessary to facilitate that and looking for low-hanging fruit
to improve user results.

- I'm likely to change the package file name and consequent naming over to
mc.  Please understand when this breaks use-package expressions.
- Autoloads are being made for 29.4 since there is no stable 30.x release
to target right now
- Mark several customize variables as safe local variables
- Generate a manual just to point users towards likely entry points like
`mc-focus' and `mc-present'
- More stable API for `mc-focus' playback

The following architecture and feature changes are planned (this is as much
rubber ducking as it is communication):

One disappointment of mine that affects both dslide and mc is the lack of
sufficient multi-monitor detection on XFCE even when xrandr is present.
The feature I want to implement is to display a frame or presentation
fullscreen on the "other" monitor because in dslide, the comments in the
base buffer are visible and can be used for narration.  At present, it
appears I would need to interpret xrandr itself since the high-level
interface Emacs ships with appears not to distinguish the two physical
monitors when they are treated as a single virtual screen.  Since we need a
new frame either way, I may just do that for now and later add customize
support to "guess" the correct location and fullscreen parameter of the new
frame.

All region selection for `mc-focus' will be re-architectured to normalize
onto the rectangle selection case.  The non-rectangle case will be
translated internally to work like the rectangle case.  The reason is that
I need to support trimming and to "do the right thing" when the user begins
the selection with indentation.  The rectangle case is more general to
every consequent problem.  This path may also adapt to handle visual lines
better, injecting newlines when the column exceeds the window column width.

I've realized a common mc workflow of mine is to hide some text completely
rather than just highlight substrings.  Subsequently, un-hiding creates the
effect of building up a larger expression with all text remaining fixed in
place, invaluable when presenting code.

The playback features of MC almost assuredly need keyword arguments.
Display can be affected by the string, its text properties, overlays, and
invisibility specs.  One option is to merge all of the properties and
overlays.  A more flexible option for interactive explanation of display
itself is to toggle the invisibility spec and overlays on the fly.  This is
unsupported during playback without retaining the "redundant" information
of unmerged properties and overlays etc.  I need to add support for
propagating overlay priorities.  Reducing all overlays is an option, but
the rules for overlays that are fully contained etc are a bit tricky and I
don't want to emulate all of the behavior within MC.

Images in theory can work.  The size of the image needs to be adjusted
according to the scale of the text overlay.  There could be edge cases.
Any specified space used for centering would need to be adjusted.  That
holds for text as well.

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

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

* Re: Introducing Master of Ceremonies, a package for presentations
  2024-12-04  2:45 ` Psionic K
@ 2024-12-04  3:01   ` Dmitry Gutov
  2024-12-04  3:13     ` Psionic K
  0 siblings, 1 reply; 7+ messages in thread
From: Dmitry Gutov @ 2024-12-04  3:01 UTC (permalink / raw)
  To: Psionic K, Emacs developers, Philip Kaludercic

Hi!

On 04/12/2024 04:45, Psionic K wrote:
> - I'm likely to change the package file name and consequent naming over 
> to mc.  Please understand when this breaks use-package expressions.

Just FWIW, there is an existing package which effectively uses the 
prefix "mc" - just following it with "/", it's called multiple-cursors, 
and it's been pretty popular a number of years ago.

Probably remains so (2.3K stars on GH).



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

* Re: Introducing Master of Ceremonies, a package for presentations
  2024-12-04  3:01   ` Dmitry Gutov
@ 2024-12-04  3:13     ` Psionic K
  0 siblings, 0 replies; 7+ messages in thread
From: Psionic K @ 2024-12-04  3:13 UTC (permalink / raw)
  To: Dmitry Gutov; +Cc: Psionic K, Emacs developers, Philip Kaludercic

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

> Just FWIW, there is an existing package which effectively uses the
> prefix "mc" - just following it with "/", it's called multiple-cursors,
> and it's been pretty popular a number of years ago.

Thanks, I hadn't seen that on MELPA, only its mc-* derivatives.

`moc' was the fallback plan.  It does not trivially complete together with
any `mc' symbols.  Anyone object to that?

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

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

* Re: Introducing Master of Ceremonies, a package for presentations
  2024-12-03 16:01 Introducing Master of Ceremonies, a package for presentations Psionic K
  2024-12-04  2:45 ` Psionic K
@ 2024-12-04  9:16 ` Jean Louis
  2024-12-04  9:55   ` Psionic K
  1 sibling, 1 reply; 7+ messages in thread
From: Jean Louis @ 2024-12-04  9:16 UTC (permalink / raw)
  To: Psionic K; +Cc: Emacs developers

* Psionic K <psionik@positron.solutions> [2024-12-03 19:03]:
> I use this package for making videos and presentations.  It's almost
> ready for archives.
> 
> https://github.com/positron-solutions/master-of-ceremonies
> https://github.com/positron-solutions/master-of-ceremonies.git

Thanks, very nice and totally useful.

But I do not need those 2 vertical lines left and right, I need it all over the screen.

I am to use it for displaying phone number and short notes or passwords which have to be observed.

Like (mc-focus "+123456678") but lines are only confusing.

-- 
Jean Louis



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

* Re: Introducing Master of Ceremonies, a package for presentations
  2024-12-04  9:16 ` Jean Louis
@ 2024-12-04  9:55   ` Psionic K
  2024-12-04 10:05     ` Psionic K
  0 siblings, 1 reply; 7+ messages in thread
From: Psionic K @ 2024-12-04  9:55 UTC (permalink / raw)
  To: Psionic K, bugs; +Cc: Emacs developers

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

Help me understand the problem more.  The current implementation uses
window margins.  If your Emacs has obviously visible margins, then the
effect is less good.  Can you set window margins to zero to see if that's
the source of your "vertical lines"?

I can switch the implementation to using specified space to overcome this
if it is indeed what we're talking about.

If there's a communication issue, feel free to drop a screenshot on a
github issue.

I have updated the git and package prefix as part of my preparation for
Non-GNU ELPA and MELPA.

https://github.com/positron-solutions/moc
https://github.com/positron-solutions/moc.git


On Wed, Dec 4, 2024 at 6:17 PM Jean Louis <bugs@gnu.support> wrote:

> * Psionic K <psionik@positron.solutions> [2024-12-03 19:03]:
> > I use this package for making videos and presentations.  It's almost
> > ready for archives.
> >
> > https://github.com/positron-solutions/master-of-ceremonies
> > https://github.com/positron-solutions/master-of-ceremonies.git
>
> Thanks, very nice and totally useful.
>
> But I do not need those 2 vertical lines left and right, I need it all
> over the screen.
>
> I am to use it for displaying phone number and short notes or passwords
> which have to be observed.
>
> Like (mc-focus "+123456678") but lines are only confusing.
>
> --
> Jean Louis
>


-- 
Only the Future is Certain

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

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

* Re: Introducing Master of Ceremonies, a package for presentations
  2024-12-04  9:55   ` Psionic K
@ 2024-12-04 10:05     ` Psionic K
  0 siblings, 0 replies; 7+ messages in thread
From: Psionic K @ 2024-12-04 10:05 UTC (permalink / raw)
  To: Psionic K, Philip Kaludercic; +Cc: Emacs developers

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

Hello Philip,

I have updated the git and package prefix as part of my preparation for
Non-GNU ELPA and MELPA.  Unless someone has a good objection in the near
future, moc is the new prefix.  There has been a short time for discussion,
but my search indicates it's not a common substring except for completing
with "mock".

https://github.com/positron-solutions/moc
https://github.com/positron-solutions/moc.git

The current package lint shows no issues and the compile is clean.  I have
added a NEWS.org and moc.texi.  The overall scheme is similar to what I
used in dslide.

I have marked code I still consider unreliably unstable / experimental with
🚧 to note areas that should be ransacked by vandals at the first
convenience.

I'm currently working on adding some kind of anti-highlight to completely
obscure a bit of text and some trimming to try and stabilize the playback
API for use in dslide.

On Wed, Dec 4, 2024 at 6:55 PM Psionic K <psionik@positron.solutions> wrote:

> Help me understand the problem more.  The current implementation uses
> window margins.  If your Emacs has obviously visible margins, then the
> effect is less good.  Can you set window margins to zero to see if that's
> the source of your "vertical lines"?
>
> I can switch the implementation to using specified space to overcome this
> if it is indeed what we're talking about.
>
> If there's a communication issue, feel free to drop a screenshot on a
> github issue.
>
> I have updated the git and package prefix as part of my preparation for
> Non-GNU ELPA and MELPA.
>
> https://github.com/positron-solutions/moc
> https://github.com/positron-solutions/moc.git
>
>
> On Wed, Dec 4, 2024 at 6:17 PM Jean Louis <bugs@gnu.support> wrote:
>
>> * Psionic K <psionik@positron.solutions> [2024-12-03 19:03]:
>> > I use this package for making videos and presentations.  It's almost
>> > ready for archives.
>> >
>> > https://github.com/positron-solutions/master-of-ceremonies
>> > https://github.com/positron-solutions/master-of-ceremonies.git
>>
>> Thanks, very nice and totally useful.
>>
>> But I do not need those 2 vertical lines left and right, I need it all
>> over the screen.
>>
>> I am to use it for displaying phone number and short notes or passwords
>> which have to be observed.
>>
>> Like (mc-focus "+123456678") but lines are only confusing.
>>
>> --
>> Jean Louis
>>
>
>
> --
> Only the Future is Certain
>


-- 
Only the Future is Certain

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

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

end of thread, other threads:[~2024-12-04 10:05 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-03 16:01 Introducing Master of Ceremonies, a package for presentations Psionic K
2024-12-04  2:45 ` Psionic K
2024-12-04  3:01   ` Dmitry Gutov
2024-12-04  3:13     ` Psionic K
2024-12-04  9:16 ` Jean Louis
2024-12-04  9:55   ` Psionic K
2024-12-04 10:05     ` Psionic K

Code repositories for project(s) associated with this public inbox

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

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 read-only IMAP folder(s) and NNTP newsgroup(s).