Re: Graphics in Linux using C

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Thankx for the reply but dont think thats gonna work all that well. Am
trying to highlight strings in a ps file. Am able to search for the
string as I have the source code for the ps file and it has been
generated from tex using the latex command and then dvips.

Now my problem is that any changes made to the source code arent quite
helpful in changing the output (the generated ps file) that you see on
ggv. I would've been able to do something by simply modifying the tex
file. But I dont have the tex file just the generated ps file. I need
to do something so that I can make changes to that.

Does anyone have any suggestions?

Am trying to highlight strings in a ps file. Am able to search for the
string. Any suggestions on how to highlight the already searched
string using C?
- Show quoted text -
On 2/9/06, STYMA, ROBERT E (ROBERT) <stymar@xxxxxxxxxx> wrote:
> >Hello
> >I want to use graphics in C to highlight text in a file.
> > Can someone tell me how to use some basic graphic
> > functions to acheive this?
> > Nimit
>
> It depends how you are going to display the file.  If you are
> writing it to a terminal window, there are a set of control
> sequences you can send to the terminal which identify
> limited coloration, including reverse video.
>
> For example:
>
> #include <stdio.h>
>
> int main(int argc, char *argv[])
> {
> char  escape = 0x1b;
> printf("%c[43mthis is a test\nmore test%c[m\n", escape, escape);
> printf("%c[7mreverse video%c[mback to normal\n", escape, escape);
> }
> The sequence is the escape character which is octal 033 or 0x1b, open
> square bracket, a code suitable to the termial, and the letter m.
> leaving out the number code resets back to normal output.
>
> I think this is what you are looking for.
>
> Bob Styma
>
> --
> fedora-list mailing list
> fedora-list@xxxxxxxxxx
> To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list
>


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux