mirror of
https://github.com/rfivet/uemacs.git
synced 2024-12-18 07:16:23 -05:00
write-message buffer adjust to full width of the terminal.
This commit is contained in:
parent
e0550db4d1
commit
2c9cbbfb1e
21
eval.c
21
eval.c
@ -1428,16 +1428,23 @@ int clrmes( int f, int n) {
|
||||
* int f, n; arguments ignored
|
||||
*/
|
||||
int writemsg( int f, int n) {
|
||||
int status;
|
||||
char buf[ NSTRING] ; /* buffer to recieve message into */
|
||||
int status ;
|
||||
int size ;
|
||||
char *buf ; /* buffer to receive message into */
|
||||
|
||||
status = mlreply( "Message to write: ", buf, sizeof buf - 1) ;
|
||||
if( status != TRUE)
|
||||
return status ;
|
||||
size = term.t_ncol + 1 ;
|
||||
buf = malloc( size) ;
|
||||
if( buf == NULL)
|
||||
return FALSE ;
|
||||
|
||||
status = mlreply( "Message to write: ", buf, size) ;
|
||||
if( status == TRUE)
|
||||
/* write the message out */
|
||||
mlforce( buf) ;
|
||||
return TRUE ;
|
||||
mlforce( buf) ;
|
||||
|
||||
free( buf) ;
|
||||
return status ;
|
||||
}
|
||||
|
||||
|
||||
/* end of eval.c */
|
||||
|
Loading…
Reference in New Issue
Block a user