Re: mupdf+firefox

2009-07-28 Thread Pawlowski Marcin Piotr
On Mon, 13 Jul 2009 23:46:53 +0100
Stuart Henderson st...@openbsd.org wrote:

 On 2009/07/13 21:34, Pawlowski Marcin Piotr wrote:
  Hi all,
  I've written two patches to use mupdf with firefox.
  First one adds WM_CLASS property to mupdf which is required by
  mozpluger. Second one simply adds mupdf to mozplugger.
 
 please would you send the mupdf diff upstream?
 thanks.

Hi,
it's upstream now.

Cheers,
pmp



Re: mupdf+firefox

2009-07-14 Thread Pawlowski Marcin Piotr
I've done it just before sending it here...

Cheers.

On Mon, 13 Jul 2009 23:46:53 +0100
Stuart Henderson st...@openbsd.org wrote:

 On 2009/07/13 21:34, Pawlowski Marcin Piotr wrote:
  Hi all,
  I've written two patches to use mupdf with firefox.
  First one adds WM_CLASS property to mupdf which is required by
  mozpluger. Second one simply adds mupdf to mozplugger.
 
 please would you send the mupdf diff upstream?
 thanks.
 
 
 
 
  
  patches:
  http://student.if.uj.edu.pl/Marcin.Pawlowski/openbsd/patches/patch-apps_unix_x11pdf_c
  http://student.if.uj.edu.pl/Marcin.Pawlowski/openbsd/patches/patch-patch-mozpluggerrc
  
  Cheers.
  
  --- apps/unix/x11pdf.c.orig Mon Jun 22 13:45:03 2009
  +++ apps/unix/x11pdf.c  Mon Jul 13 18:50:34 2009
  @@ -69,6 +69,8 @@
   static char copylatin1[1024 * 16] = ;
   static char copyutf8[1024 * 48] = ;
   static Time copytime;
  +static char MyXName[6] = mupdf;
  +static char MyXClass[6] = Mupdf;
   
   static pdfapp_t gapp;
   
  @@ -101,6 +103,7 @@
   void winopen(void)
   {
  XWMHints *hints;
  +   XClassHint *classHint;
   
  xdpy = XOpenDisplay(nil);
  if (!xdpy)
  @@ -159,6 +162,16 @@
  XSetWMHints(xdpy, xwin, hints);
  }
  XFree(hints);
  +   }
  +   
  +   classHint = XAllocClassHint();
  +
  +   if (classHint)
  +   {
  +   classHint-res_name = MyXName;
  +   classHint-res_class = MyXClass;
  +   XSetClassHint(xdpy, xwin, classHint);
  +   XFree(classHint);
  }
   
  x11fd = ConnectionNumber(xdpy);
  
  
  --- patch-mozpluggerrc.orig Mon Jul 13 20:11:55 2009
  +++ patch-mozpluggerrc  Mon Jul 13 21:09:26 2009
  @@ -78,7 +78,7 @@
video/x-theora:ogg:OGG stream with video
video/theora:ogg:OGG stream with video
video/ogg:ogg:OGG stream with video
  -@@ -148,138 +153,137 @@ video/x-anim:iff,anim5,anim3,anim7:IFF
  animation +@@ -148,138 +153,138 @@
  video/x-anim:iff,anim5,anim3,anim7:IFF animation ### Audio  ###
##

  @@ -322,6 +322,7 @@
   +  repeat noisy swallow(evince) fill: evince $file
   +  repeat swallow(acroread) fill: acroread -openInNewWindow
  $file repeat noisy swallow(Xpdf) fill: xpdf -g +9000+9000 $file
  ++  repeat noisy swallow(mupdf) fill: mupdf $file
  GV()

   @@ -289,78 +293,79 @@ application/x-dvi:dvi:DVI file
  



Re: mupdf+firefox

2009-07-14 Thread Roberto Fernandez
sorry, I replyed instead of group-reply :(

On Mon, Jul 13, 2009 at 11:46:53PM +0100, Stuart Henderson wrote:
 On 2009/07/13 21:34, Pawlowski Marcin Piotr wrote:
  Hi all,
  I've written two patches to use mupdf with firefox.
  First one adds WM_CLASS property to mupdf which is required by
  mozpluger. Second one simply adds mupdf to mozplugger.
 
 please would you send the mupdf diff upstream?
 thanks.

I've a similar patch in my tree too, but it's not correct.
When you configure your WM to open mupdf fullscreen, mupdf have no clue
on it's window size.

as an example, for openbox:
in ~/.config/openbox/rc.xml
...
 applications
application name=mupdf
  maximizedyes/maximized
  decorno/decor
/application
  /applications
/openbox_config


will scow up the screen.



Re: mupdf+firefox

2009-07-14 Thread David Coppa
There's also a plugin in form of a firefox xpi:

http://ccxvii.net/mupdf/plugin/install.html

cheers,
David

On Tue, Jul 14, 2009 at 10:55 AM, Pawlowski Marcin
Piotrpawlowski...@gmail.com wrote:
 I've done it just before sending it here...

 Cheers.

 On Mon, 13 Jul 2009 23:46:53 +0100
 Stuart Henderson st...@openbsd.org wrote:

 On 2009/07/13 21:34, Pawlowski Marcin Piotr wrote:
  Hi all,
  I've written two patches to use mupdf with firefox.
  First one adds WM_CLASS property to mupdf which is required by
  mozpluger. Second one simply adds mupdf to mozplugger.

 please would you send the mupdf diff upstream?
 thanks.



Re: mupdf+firefox

2009-07-14 Thread Roberto Fernandez
On Tue, Jul 14, 2009 at 11:33:44AM +0200, David Coppa wrote:
 There's also a plugin in form of a firefox xpi:
 
 http://ccxvii.net/mupdf/plugin/install.html

win32 only !

Click here to install the MuPDF Plug-in for Firefox on Windows.
 ~~



Re: mupdf+firefox

2009-07-13 Thread Stuart Henderson
On 2009/07/13 21:34, Pawlowski Marcin Piotr wrote:
 Hi all,
 I've written two patches to use mupdf with firefox.
 First one adds WM_CLASS property to mupdf which is required by
 mozpluger. Second one simply adds mupdf to mozplugger.

please would you send the mupdf diff upstream?
thanks.




 
 patches:
 http://student.if.uj.edu.pl/Marcin.Pawlowski/openbsd/patches/patch-apps_unix_x11pdf_c
 http://student.if.uj.edu.pl/Marcin.Pawlowski/openbsd/patches/patch-patch-mozpluggerrc
 
 Cheers.
 
 --- apps/unix/x11pdf.c.orig   Mon Jun 22 13:45:03 2009
 +++ apps/unix/x11pdf.cMon Jul 13 18:50:34 2009
 @@ -69,6 +69,8 @@
  static char copylatin1[1024 * 16] = ;
  static char copyutf8[1024 * 48] = ;
  static Time copytime;
 +static char MyXName[6] = mupdf;
 +static char MyXClass[6] = Mupdf;
  
  static pdfapp_t gapp;
  
 @@ -101,6 +103,7 @@
  void winopen(void)
  {
   XWMHints *hints;
 + XClassHint *classHint;
  
   xdpy = XOpenDisplay(nil);
   if (!xdpy)
 @@ -159,6 +162,16 @@
   XSetWMHints(xdpy, xwin, hints);
   }
   XFree(hints);
 + }
 + 
 + classHint = XAllocClassHint();
 +
 + if (classHint)
 + {
 + classHint-res_name = MyXName;
 + classHint-res_class = MyXClass;
 + XSetClassHint(xdpy, xwin, classHint);
 + XFree(classHint);
   }
  
   x11fd = ConnectionNumber(xdpy);
 
 
 --- patch-mozpluggerrc.orig   Mon Jul 13 20:11:55 2009
 +++ patch-mozpluggerrcMon Jul 13 21:09:26 2009
 @@ -78,7 +78,7 @@
   video/x-theora:ogg:OGG stream with video
   video/theora:ogg:OGG stream with video
   video/ogg:ogg:OGG stream with video
 -@@ -148,138 +153,137 @@ video/x-anim:iff,anim5,anim3,anim7:IFF
 animation +@@ -148,138 +153,138 @@
 video/x-anim:iff,anim5,anim3,anim7:IFF animation ### Audio  ###
   ##
   
 @@ -322,6 +322,7 @@
  +repeat noisy swallow(evince) fill: evince $file
  +repeat swallow(acroread) fill: acroread -openInNewWindow
 $file repeat noisy swallow(Xpdf) fill: xpdf -g +9000+9000 $file
 ++repeat noisy swallow(mupdf) fill: mupdf $file
   GV()
   
  @@ -289,78 +293,79 @@ application/x-dvi:dvi:DVI file