On 2014-08-14 17:54:03, Igor Almeida wrote: > Hi, > > I'd like to implement a 'float selection' functionality, to be able > to extract some selected region (maybe with right-click, to distinguish > from current behavior?) to a separate window. > This would be useful for keeping a diagram visible while I read its > description along the original document's text, for example. With a long > enough text, eventually you need to scroll and lose sight of what the > document is referring to. > > Can anyone offer hints as to how I could implement that with zathura? > > Today, I can mimic that by opening a second instance and shrinking the > window to fit only what I want to see, which is far from ideal. > > I'm not really sure if this needs to be specific to the PDF plugin, but > that's my main goal for now. > > Any help is appreciated.
So, there is already code to store the text of a selected area in the clipboard. I think you can adapt the code to just copy parts of the rendered image instead of the text. See page-widget.c for details. In particular cb_zathura_page_widget_button_release_event. Let me know if you need more info. Cheers -- Sebastian Ramacher _______________________________________________ zathura mailing list firstname.lastname@example.org http://lists.pwmt.org/mailman/listinfo/zathura