Pango pipe stdin and stdout

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Pango pipe stdin and stdout

Adam Dyson

I’d like to know whether it’s possible to render text using Pango, by piping text as input to stdin and then also piping the result to stdout?

Ideally I’m wanting something like below, where an argument such as intent defines the output type, because this is normally determined by the output file extension.

Outputting to stdout is defined by a dash and so is reading from stdin, which is common practice for command line utilities.

 

pango-view –q --markup --align=left --margin=0 –intent=svg --output=- -

 


_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list
Reply | Threaded
Open this post in threaded view
|

Re: Pango pipe stdin and stdout

Dov Grobgeld-2
Please check out paps which was written for that exact purpose. It can be installed through dnf on Fedora/Centos and probably by apt-get on Debian (like) systems. You can find the sources in my github repo at:

https://github.com/dov/paps

Regards,
Dov

On Sat, Jun 3, 2017 at 4:43 PM, Adam Dyson <[hidden email]> wrote:

I’d like to know whether it’s possible to render text using Pango, by piping text as input to stdin and then also piping the result to stdout?

Ideally I’m wanting something like below, where an argument such as intent defines the output type, because this is normally determined by the output file extension.

Outputting to stdout is defined by a dash and so is reading from stdin, which is common practice for command line utilities.

 

pango-view –q --markup --align=left --margin=0 –intent=svg --output=- -

 


_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list



_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list
Reply | Threaded
Open this post in threaded view
|

Re: Pango pipe stdin and stdout

Behdad Esfahbod-3
In reply to this post by Adam Dyson
Looks like I did all of those in hb-view, but not pango-view... So, no, it's not currently possible.  Try paps indeed.

On Sat, Jun 3, 2017 at 6:43 AM, Adam Dyson <[hidden email]> wrote:

I’d like to know whether it’s possible to render text using Pango, by piping text as input to stdin and then also piping the result to stdout?

Ideally I’m wanting something like below, where an argument such as intent defines the output type, because this is normally determined by the output file extension.

Outputting to stdout is defined by a dash and so is reading from stdin, which is common practice for command line utilities.

 

pango-view –q --markup --align=left --margin=0 –intent=svg --output=- -

 


_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list




--

_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list
Reply | Threaded
Open this post in threaded view
|

Re: Pango pipe stdin and stdout

Adam Dyson
Is this ever likely to be built into Pango directly? Looking at the paps repository, it doesn't seem to be updated regularly and I don't want to add another dependency if not needed and especially one that isn't going to be maintained.

On 7 Jun 2017, at 7:25 pm, Behdad Esfahbod <[hidden email]> wrote:

Looks like I did all of those in hb-view, but not pango-view... So, no, it's not currently possible.  Try paps indeed.

On Sat, Jun 3, 2017 at 6:43 AM, Adam Dyson <[hidden email]> wrote:

I’d like to know whether it’s possible to render text using Pango, by piping text as input to stdin and then also piping the result to stdout?

Ideally I’m wanting something like below, where an argument such as intent defines the output type, because this is normally determined by the output file extension.

Outputting to stdout is defined by a dash and so is reading from stdin, which is common practice for command line utilities.

 

pango-view –q --markup --align=left --margin=0 –intent=svg --output=- -

 


_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list




--

_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list
Reply | Threaded
Open this post in threaded view
|

Re: Pango pipe stdin and stdout

Behdad Esfahbod-3
I don't think I'll get to do that anytime soon. Feel free to submit a patch. Is rather straightforward.  The "intent" option is called --output-format in hb-view.

On Jun 8, 2017 7:18 AM, "Adam Dyson" <[hidden email]> wrote:
Is this ever likely to be built into Pango directly? Looking at the paps repository, it doesn't seem to be updated regularly and I don't want to add another dependency if not needed and especially one that isn't going to be maintained.

On 7 Jun 2017, at 7:25 pm, Behdad Esfahbod <[hidden email]> wrote:

Looks like I did all of those in hb-view, but not pango-view... So, no, it's not currently possible.  Try paps indeed.

On Sat, Jun 3, 2017 at 6:43 AM, Adam Dyson <[hidden email]> wrote:

I’d like to know whether it’s possible to render text using Pango, by piping text as input to stdin and then also piping the result to stdout?

Ideally I’m wanting something like below, where an argument such as intent defines the output type, because this is normally determined by the output file extension.

Outputting to stdout is defined by a dash and so is reading from stdin, which is common practice for command line utilities.

 

pango-view –q --markup --align=left --margin=0 –intent=svg --output=- -

 


_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list




--

_______________________________________________
gtk-i18n-list mailing list
[hidden email]
https://mail.gnome.org/mailman/listinfo/gtk-i18n-list