GNU bug report logs - #45140
28.0.50; rendering c source on the tty inside virtual console

Previous Next

Package: emacs;

Reported by: rrandresf <at> gmail.com

Date: Wed, 9 Dec 2020 17:36:02 UTC

Severity: normal

Tags: moreinfo

Found in version 28.0.50

Done: Stefan Kangas <stefan <at> marxist.se>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 45140 in the body.
You can then email your comments to 45140 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-gnu-emacs <at> gnu.org:
bug#45140; Package emacs. (Wed, 09 Dec 2020 17:36:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to rrandresf <at> gmail.com:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Wed, 09 Dec 2020 17:36:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: rrandresf <at> gmail.com
To: bug-gnu-emacs <at> gnu.org
Subject: 28.0.50; rendering c source on the tty inside virtual console
Date: Wed, 09 Dec 2020 17:34:25 +0000
[Message part 1 (text/plain, inline)]
Hi. Guys.

On emacs 27.1 emacs on the tty renders pretty fine.
[tty3-screenshot-27.1.png (image/png, attachment)]
[Message part 3 (text/plain, inline)]
On emacs 28.0.50 the colors has changed (read quality was better on 27)

[tty4-screenshot-28.0.50.png (image/png, attachment)]
[Message part 5 (text/plain, inline)]
Part of source code (Just in case)
[edi_tracking_bean.c (text/plain, inline)]
// tx_ok set here in case of online; TODO: mark the retry case before calling this func
void edi_tracking_bean_check_ticket_status(edi_tracking_bean_t self) {
  inv_company_t company_bean;
  credentials_t credentials;
  buffer_t text_4_template_xml;
  buffer_t text_inc_as_json_data_ptr;
  buffer_t text_out;
  const char *template_name_4_verbosity;
  Err error;
  bool flag; 

  flag = true;
  credentials = (credentials_t)objects_search(self-> app_objects, (int)credentials_free);
  company_bean = credentials_get_company_bean(credentials);

  // export_company_data_for_edi_ticket_status
  text_inc_as_json_data_ptr = inv_company_short_info_for_getting_ticket_status_to_json(company_bean, edi_tracking_bean_get_ticket_number(self));
  if (!text_inc_as_json_data_ptr || (buffer_len(text_inc_as_json_data_ptr) < 1)) {
    fprintf(stderr, "Err\n edi_tracking_bean_check_ticket_status issue on inv_company_short_info_for_getting_ticket_status_to_json %s\n", (const char*)buffer_ptr(text_inc_as_json_data_ptr));
    inv_error_bean_set_data_helper(contrErrElectronicInvoicePoliIssue, "edi_tracking_bean_check_ticket_status issue on inv_company_short_info_for_getting_ticket_status_to_json", &error);
    flag = false;
  }
  
  //get_line_content_template
  template_name_4_verbosity = "electronic_invoice_get_ticket_status";
  text_out = buffer_alloc (DEFAULT_ARRAY_SIZE);
  text_4_template_xml = buffer_alloc( DEFAULT_ARRAY_SIZE );
  contr_print_get_printer_resource_template_from_database(credentials_get_conn(credentials), template_name_4_verbosity, text_4_template_xml, &error);
  if (buffer_len(text_4_template_xml) < 1) {
    fprintf(stderr, "Err\n edi_tracking_bean_check_ticket_status issue on contr_print_get_printer_template_from_database %s\n", template_name_4_verbosity);
    inv_error_bean_set_data_helper(contrSaleErrPrintingIssue, "printer template is not present", &error);
    flag = false;
  }

  if (flag) {
    flag = contr_print_merge((const char*)buffer_ptr(text_inc_as_json_data_ptr), (const char*)buffer_ptr(text_4_template_xml), template_name_4_verbosity, text_out, &error);
    if (flag) {
      edi_tracking_bean_set_post_data_for_ticket_status(self, (const char*)buffer_ptr(text_out));
      flag = _edi_tracking_bean_check_ticket_status_helper(self, credentials, &error); // send
      if (flag) {
        // if_ok, {printf log.info} {inspect and analyze xml_result -> <content> <statusCode>} {0127|0|98|99}
        edi_tracking_bean_set_was_transaction_ok(self);
      }
    }
  }

  buffer_free(text_4_template_xml);
  buffer_free(text_out);
}
[Message part 7 (text/plain, inline)]
Best Regards
ps: Ctrl+Alt+F3 {for going to tty3; and then emacsclient -c -t}


In GNU Emacs 28.0.50 (build 2, armv7l-unknown-linux-gnueabihf, X toolkit, cairo version 1.17.3, Xaw3d scroll bars)
 of 2020-12-09 built on sacsa
Windowing system distributor 'The X.Org Foundation', version 11.0.12009000
System Description: Arch Linux ARM

Configured using:
 'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
 --localstatedir=/var --with-x-toolkit=lucid --with-xft --without-gconf
 --without-gsettings --with-modules
 '--program-transform-name=s/^ctags$/ctags.emacs/' --without-pop
 --with-wide-int --with-json=yes 'CFLAGS=-march=armv7-a -mfloat-abi=hard
 -mfpu=vfpv3-d16 -O2 -pipe -fstack-protector-strong -fno-plt'
 CPPFLAGS=-D_FORTIFY_SOURCE=2
 LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now'

Configured features:
XAW3D XPM JPEG TIFF GIF PNG RSVG CAIRO SOUND GPM DBUS GLIB NOTIFY
INOTIFY ACL GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF ZLIB
TOOLKIT_SCROLL_BARS LUCID X11 XDBE XIM MODULES THREADS LIBSYSTEMD JSON
PDUMPER LCMS2

Important settings:
  value of $LC_COLLATE: C
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8-unix

Major mode: Lisp Interaction

Minor modes in effect:
  tooltip-mode: t
  global-eldoc-mode: t
  eldoc-mode: t
  electric-indent-mode: t
  mouse-wheel-mode: t
  tool-bar-mode: t
  menu-bar-mode: t
  file-name-shadow-mode: t
  global-font-lock-mode: t
  font-lock-mode: t
  blink-cursor-mode: t
  auto-composition-mode: t
  auto-encryption-mode: t
  auto-compression-mode: t
  line-number-mode: t
  transient-mark-mode: t

Load-path shadows:
None found.

Features:
(shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
rfc822 mml easymenu mml-sec epa derived epg epg-config gnus-util rmail
rmail-loaddefs auth-source cl-seq eieio eieio-core cl-macs
eieio-loaddefs password-cache json map text-property-search time-date
subr-x seq byte-opt gv bytecomp byte-compile cconv mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs
cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
iso-transl tooltip eldoc electric uniquify ediff-hook vc-hooks
lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar
dnd fontset image regexp-opt fringe tabulated-list replace newcomment
text-mode elisp-mode lisp-mode prog-mode register page tab-bar menu-bar
rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock
syntax facemenu font-core term/tty-colors frame minibuffer cl-generic
cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
european ethiopic indian cyrillic chinese composite charscript charprop
case-table epa-hook jka-cmpr-hook help simple abbrev obarray
cl-preloaded nadvice button loaddefs faces cus-face macroexp files
window text-properties overlay sha1 md5 base64 format env code-pages
mule custom widget hashtable-print-readable backquote threads dbusbind
inotify lcms2 dynamic-setting font-render-setting cairo x-toolkit x
multi-tty make-network-process emacs)

Memory information:
((conses 16 52810 10166)
 (symbols 48 7064 1)
 (strings 16 19280 2077)
 (string-bytes 1 614498)
 (vectors 16 12353)
 (vector-slots 8 176032 10074)
 (floats 8 23 43)
 (intervals 40 236 6)
 (buffers 872 10))

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#45140; Package emacs. (Mon, 11 Oct 2021 12:15:02 GMT) Full text and rfc822 format available.

Message #8 received at 45140 <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: rrandresf <at> gmail.com
Cc: 45140 <at> debbugs.gnu.org, Alan Mackenzie <acm <at> muc.de>
Subject: Re: bug#45140: 28.0.50;
 rendering c source on the tty inside virtual console
Date: Mon, 11 Oct 2021 05:14:28 -0700
rrandresf <at> gmail.com writes:

> Hi. Guys.
>
> On emacs 27.1 emacs on the tty renders pretty fine.
>
>
>
> On emacs 28.0.50 the colors has changed (read quality was better on 27)

So I guess this is about highlighting in cc-mode?  Alan, any idea if
anything has changed in this area?

Screenshots are in:
https://debbugs.gnu.org/cgi/bugreport.cgi?bug=45140

> Part of source code (Just in case)
>
> // tx_ok set here in case of online; TODO: mark the retry case before calling this func
> void edi_tracking_bean_check_ticket_status(edi_tracking_bean_t self) {
>   inv_company_t company_bean;
>   credentials_t credentials;
>   buffer_t text_4_template_xml;
>   buffer_t text_inc_as_json_data_ptr;
>   buffer_t text_out;
>   const char *template_name_4_verbosity;
>   Err error;
>   bool flag;
>
>   flag = true;
>   credentials = (credentials_t)objects_search(self-> app_objects, (int)credentials_free);
>   company_bean = credentials_get_company_bean(credentials);
>
>   // export_company_data_for_edi_ticket_status
>   text_inc_as_json_data_ptr = inv_company_short_info_for_getting_ticket_status_to_json(company_bean, edi_tracking_bean_get_ticket_number(self));
>   if (!text_inc_as_json_data_ptr || (buffer_len(text_inc_as_json_data_ptr) < 1)) {
>     fprintf(stderr, "Err\n edi_tracking_bean_check_ticket_status issue on inv_company_short_info_for_getting_ticket_status_to_json %s\n", (const char*)buffer_ptr(text_inc_as_json_data_ptr));
>     inv_error_bean_set_data_helper(contrErrElectronicInvoicePoliIssue, "edi_tracking_bean_check_ticket_status issue on inv_company_short_info_for_getting_ticket_status_to_json", &error);
>     flag = false;
>   }
>
>   //get_line_content_template
>   template_name_4_verbosity = "electronic_invoice_get_ticket_status";
>   text_out = buffer_alloc (DEFAULT_ARRAY_SIZE);
>   text_4_template_xml = buffer_alloc( DEFAULT_ARRAY_SIZE );
>   contr_print_get_printer_resource_template_from_database(credentials_get_conn(credentials), template_name_4_verbosity, text_4_template_xml, &error);
>   if (buffer_len(text_4_template_xml) < 1) {
>     fprintf(stderr, "Err\n edi_tracking_bean_check_ticket_status issue on contr_print_get_printer_template_from_database %s\n", template_name_4_verbosity);
>     inv_error_bean_set_data_helper(contrSaleErrPrintingIssue, "printer template is not present", &error);
>     flag = false;
>   }
>
>   if (flag) {
>     flag = contr_print_merge((const char*)buffer_ptr(text_inc_as_json_data_ptr), (const char*)buffer_ptr(text_4_template_xml), template_name_4_verbosity, text_out, &error);
>     if (flag) {
>       edi_tracking_bean_set_post_data_for_ticket_status(self, (const char*)buffer_ptr(text_out));
>       flag = _edi_tracking_bean_check_ticket_status_helper(self, credentials, &error); // send
>       if (flag) {
>         // if_ok, {printf log.info} {inspect and analyze xml_result -> <content> <statusCode>} {0127|0|98|99}
>         edi_tracking_bean_set_was_transaction_ok(self);
>       }
>     }
>   }
>
>   buffer_free(text_4_template_xml);
>   buffer_free(text_out);
> }
>
>
> Best Regards
> ps: Ctrl+Alt+F3 {for going to tty3; and then emacsclient -c -t}
>
>
> In GNU Emacs 28.0.50 (build 2, armv7l-unknown-linux-gnueabihf, X toolkit, cairo version 1.17.3, Xaw3d scroll bars)
>  of 2020-12-09 built on sacsa
> Windowing system distributor 'The X.Org Foundation', version 11.0.12009000
> System Description: Arch Linux ARM
>
> Configured using:
>  'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
>  --localstatedir=/var --with-x-toolkit=lucid --with-xft --without-gconf
>  --without-gsettings --with-modules
>  '--program-transform-name=s/^ctags$/ctags.emacs/' --without-pop
>  --with-wide-int --with-json=yes 'CFLAGS=-march=armv7-a -mfloat-abi=hard
>  -mfpu=vfpv3-d16 -O2 -pipe -fstack-protector-strong -fno-plt'
>  CPPFLAGS=-D_FORTIFY_SOURCE=2
>  LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now'
>
> Configured features:
> XAW3D XPM JPEG TIFF GIF PNG RSVG CAIRO SOUND GPM DBUS GLIB NOTIFY
> INOTIFY ACL GNUTLS LIBXML2 FREETYPE HARFBUZZ M17N_FLT LIBOTF ZLIB
> TOOLKIT_SCROLL_BARS LUCID X11 XDBE XIM MODULES THREADS LIBSYSTEMD JSON
> PDUMPER LCMS2
>
> Important settings:
>   value of $LC_COLLATE: C
>   value of $LANG: en_US.UTF-8
>   locale-coding-system: utf-8-unix
>
> Major mode: Lisp Interaction
>
> Minor modes in effect:
>   tooltip-mode: t
>   global-eldoc-mode: t
>   eldoc-mode: t
>   electric-indent-mode: t
>   mouse-wheel-mode: t
>   tool-bar-mode: t
>   menu-bar-mode: t
>   file-name-shadow-mode: t
>   global-font-lock-mode: t
>   font-lock-mode: t
>   blink-cursor-mode: t
>   auto-composition-mode: t
>   auto-encryption-mode: t
>   auto-compression-mode: t
>   line-number-mode: t
>   transient-mark-mode: t
>
> Load-path shadows:
> None found.
>
> Features:
> (shadow sort mail-extr emacsbug message rmc puny dired dired-loaddefs
> rfc822 mml easymenu mml-sec epa derived epg epg-config gnus-util rmail
> rmail-loaddefs auth-source cl-seq eieio eieio-core cl-macs
> eieio-loaddefs password-cache json map text-property-search time-date
> subr-x seq byte-opt gv bytecomp byte-compile cconv mm-decode mm-bodies
> mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader cl-loaddefs
> cl-lib sendmail rfc2047 rfc2045 ietf-drums mm-util mail-prsvr mail-utils
> iso-transl tooltip eldoc electric uniquify ediff-hook vc-hooks
> lisp-float-type mwheel term/x-win x-win term/common-win x-dnd tool-bar
> dnd fontset image regexp-opt fringe tabulated-list replace newcomment
> text-mode elisp-mode lisp-mode prog-mode register page tab-bar menu-bar
> rfn-eshadow isearch timer select scroll-bar mouse jit-lock font-lock
> syntax facemenu font-core term/tty-colors frame minibuffer cl-generic
> cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao
> korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech
> european ethiopic indian cyrillic chinese composite charscript charprop
> case-table epa-hook jka-cmpr-hook help simple abbrev obarray
> cl-preloaded nadvice button loaddefs faces cus-face macroexp files
> window text-properties overlay sha1 md5 base64 format env code-pages
> mule custom widget hashtable-print-readable backquote threads dbusbind
> inotify lcms2 dynamic-setting font-render-setting cairo x-toolkit x
> multi-tty make-network-process emacs)
>
> Memory information:
> ((conses 16 52810 10166)
>  (symbols 48 7064 1)
>  (strings 16 19280 2077)
>  (string-bytes 1 614498)
>  (vectors 16 12353)
>  (vector-slots 8 176032 10074)
>  (floats 8 23 43)
>  (intervals 40 236 6)
>  (buffers 872 10))




Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#45140; Package emacs. (Mon, 11 Oct 2021 15:12:02 GMT) Full text and rfc822 format available.

Message #11 received at 45140 <at> debbugs.gnu.org (full text, mbox):

From: Alan Mackenzie <acm <at> muc.de>
To: rrandresf <at> gmail.com
Cc: 45140 <at> debbugs.gnu.org, Stefan Kangas <stefan <at> marxist.se>
Subject: Re: bug#45140: 28.0.50; rendering c source on the tty inside virtual
 console
Date: Mon, 11 Oct 2021 15:11:13 +0000
Hello, rrandresf.

Firstly, sorry about missing your bug report last December.

Secondly, it's great to see somebody else using the Linux tty!

On Wed, Dec 09, 2020 at 17:34:25 +0000, rrandresf <at> gmail.com wrote:

> Hi. Guys.

> On emacs 27.1 emacs on the tty renders pretty fine.



> On emacs 28.0.50 the colors has changed (read quality was better on 27)

It looks like the fontification was unfinished on that screen.  For
example, strings and comments get fontified, but the variable
declarations didn't.  I hope that was a bug in CC Mode which has long
been fixed.  When that happens, there is often an error message in the
*Messages* buffer, which you can see with C-h e.

Was there anything else about the reduction in quality you mention?  I
think your yellow strings was something you configured yourself, for
example.

Is the problem still there in the savannah master branch, or what has
now become the Emacs-28 release branch?

> Part of source code (Just in case)

[ ....  Thanks! ]

> Best Regards
> ps: Ctrl+Alt+F3 {for going to tty3; and then emacsclient -c -t}

Yes.  ;-)

> In GNU Emacs 28.0.50 (build 2, armv7l-unknown-linux-gnueabihf, X toolkit, cairo version 1.17.3, Xaw3d scroll bars)
>  of 2020-12-09 built on sacsa
> Windowing system distributor 'The X.Org Foundation', version 11.0.12009000
> System Description: Arch Linux ARM

> Configured using:
>  'configure --prefix=/usr --sysconfdir=/etc --libexecdir=/usr/lib
>  --localstatedir=/var --with-x-toolkit=lucid --with-xft --without-gconf
>  --without-gsettings --with-modules
>  '--program-transform-name=s/^ctags$/ctags.emacs/' --without-pop
>  --with-wide-int --with-json=yes 'CFLAGS=-march=armv7-a -mfloat-abi=hard
>  -mfpu=vfpv3-d16 -O2 -pipe -fstack-protector-strong -fno-plt'
>  CPPFLAGS=-D_FORTIFY_SOURCE=2
>  LDFLAGS=-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now'

[ .... ]

-- 
Alan Mackenzie (Nuremberg, Germany).




Added tag(s) moreinfo. Request was from Stefan Kangas <stefan <at> marxist.se> to control <at> debbugs.gnu.org. (Mon, 11 Oct 2021 19:17:03 GMT) Full text and rfc822 format available.

Information forwarded to bug-gnu-emacs <at> gnu.org:
bug#45140; Package emacs. (Fri, 15 Oct 2021 03:28:01 GMT) Full text and rfc822 format available.

Message #16 received at 45140 <at> debbugs.gnu.org (full text, mbox):

From: andrés ramírez <rrandresf <at> gmail.com>
To: Alan Mackenzie <acm <at> muc.de>
Cc: 45140 <at> debbugs.gnu.org, Stefan Kangas <stefan <at> marxist.se>
Subject: Re: bug#45140: 28.0.50; rendering c source on the tty inside
 virtual console
Date: Fri, 15 Oct 2021 03:27:24 +0000
Hi. Alan. Hi. Stefan.
My comments below.

>>>>> "Alan" == Alan Mackenzie <acm <at> muc.de> writes:
    Alan> Hello, rrandresf.  Firstly, sorry about missing your bug report last December.
    Alan> Secondly, it's great to see somebody else using the Linux tty!

Right. Alan. tty is quick and awesome. Excellent for the eyes.

[...]

    Alan> Is the problem still there in the savannah master branch, or what has now become the
    Alan> Emacs-28 release branch?

I have just checked. That it has been fixed on the emacs-28 release
branch. So I think the bug could be closed. Thanks for work guys.

Best Regards




Reply sent to Stefan Kangas <stefan <at> marxist.se>:
You have taken responsibility. (Sun, 24 Oct 2021 07:59:01 GMT) Full text and rfc822 format available.

Notification sent to rrandresf <at> gmail.com:
bug acknowledged by developer. (Sun, 24 Oct 2021 07:59:01 GMT) Full text and rfc822 format available.

Message #21 received at 45140-done <at> debbugs.gnu.org (full text, mbox):

From: Stefan Kangas <stefan <at> marxist.se>
To: andrés ramírez <rrandresf <at> gmail.com>
Cc: Alan Mackenzie <acm <at> muc.de>, 45140-done <at> debbugs.gnu.org
Subject: Re: bug#45140: 28.0.50;
 rendering c source on the tty inside virtual console
Date: Sun, 24 Oct 2021 00:58:26 -0700
andrés ramírez <rrandresf <at> gmail.com> writes:

> Hi. Alan. Hi. Stefan.
> My comments below.
>
>>>>>> "Alan" == Alan Mackenzie <acm <at> muc.de> writes:
>     Alan> Hello, rrandresf.  Firstly, sorry about missing your bug report last December.
>     Alan> Secondly, it's great to see somebody else using the Linux tty!
>
> Right. Alan. tty is quick and awesome. Excellent for the eyes.
>
> [...]
>
>     Alan> Is the problem still there in the savannah master branch, or what has now become the
>     Alan> Emacs-28 release branch?
>
> I have just checked. That it has been fixed on the emacs-28 release
> branch. So I think the bug could be closed. Thanks for work guys.

Thanks, I'm therefore closing this bug report.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sun, 21 Nov 2021 12:24:05 GMT) Full text and rfc822 format available.

This bug report was last modified 2 years and 157 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.