Ncurses does not display text that should be flashing

OP (Company: no) #5068603
Rate this post
• ▲ useful
▼ not useful
1
#include <ncurses.h>
2
#include <locale.h>
3
#include <unistd.h>
4
#include <string.h>
5

6
int main()
7
{
8
  setlocale(LC_ALL, "");
9
  
10
    initscr();
11
    
12
     char str[]={"Hello world!"};
13
     for(int i=0; i<strlen(str); i++)
14
     {
15
         addch(str[i] | A_BLINK);
16
     }
17
     refresh();
18
     getch();
19
    
20
    endwin();              
21
    return 0;
22
}
After compiling and executing this code, I do not see any flashing text, 
just output a string.
Do you have the same thing?
I'm writing on armv7
Guest #5069597
Rate this post
• ▲ useful
▼ not useful
Only a few terminal emulators support blinking (some may just highlight 
it by other means); part of the reason is that it's very obnoxious. For 
remotely portable blinking you will need to periodically redraw the 
text.
OP (Company: no) #5070223
Rate this post
• ▲ useful
▼ not useful
Jemand wrote:
> Only a few terminal emulators support blinking (some may just highlight
> it by other means); part of the reason is that it's very obnoxious. For
> remotely portable blinking you will need to periodically redraw the
> text.

This is a very necessary function, I already put arm xterm and now 
everything works. For the sake of such beauty you can and suffer.

Reply

A question of your own? This thread is over 9 years old. Ask it in a thread of its own – more people read along there, and it gets answered more often and sooner.

Start a new thread

A fix, an addition or feedback on this thread? Then reply here.

Formatting
  • [c]C-Code[/c]
  • [code]code in other languages, ASCII drawings[/code]
  • [math]formula (LaTeX syntax)[/math]
  • [[Title]] – link to an article
  • Link to another post: right-click its post ID (#8078628), copy the address, paste it into the text

More about formatting

Post long source code as an attachment, not in the text.

Already registered? Log in

Not shown to anyone. We send you a link; your post appears once you confirm it there.

By submitting you create a free account and accept the terms of use.