unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Jiajian Huang <wherejoystarts@gmail.com>
To: 24271@debbugs.gnu.org
Subject: bug#24271: 25.1; font-lock problem of c++-mode
Date: Sat, 20 Aug 2016 08:42:43 +0800	[thread overview]
Message-ID: <7756A5F1-342F-4F55-8D6B-1A41B528DE5A@gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 3545 bytes --]


I recently notice that there's some strange behaviours of the font-lock of the c++-mode.

Let's start emacs by `emacs -Q` in the terminal, edit a new file `test.cpp` and save the following contents



Then put the cursor two lines above the `int main` line, type `int test`, you will find that the color of word `main` changes from *blue* to *black*



Backspace the current line to `in` or `i`, you will see that the color of `main` change back to *blue*



This is not a very big problem under this test, but I use color theme that the function names are in *bold* type. So when I add a function above another function, the font-lock of the below one keep changing all the time which is really annoying.

Is this a emacs bug ? I want *bold* function name and other *bold* keywords but how can I get rid of it ? Any help will be appreciated.


In GNU Emacs 25.1.1 (x86_64-apple-darwin13.4.0, NS appkit-1265.21 Version 10.9.5 (Build 13F1911))
of 2016-07-25 built on builder10-9.porkrind.org
Windowing system distributor 'Apple', version 10.3.1404
Configured using:
'configure --with-ns '--enable-locallisppath=/Library/Application
Support/Emacs/${version}/site-lisp:/Library/Application
Support/Emacs/site-lisp''

Configured features:
NOTIFY ACL LIBXML2 ZLIB TOOLKIT_SCROLL_BARS NS

Important settings:
  value of $LC_ALL: en_US.UTF-8
  value of $LC_CTYPE: UTF-8
  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
  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

Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Entering debugger...
Quit
Type C-x 1 to delete the help window.
Quit

Load-path shadows:
None found.

Features:
(shadow sort mail-extr debug emacsbug message dired format-spec rfc822
mml mml-sec password-cache epg epg-config gnus-util mm-decode mm-bodies
mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail
rfc2047 rfc2045 ietf-drums mm-util help-fns help-mode easymenu
cl-loaddefs pcase cl-lib mail-prsvr mail-utils time-date mule-util
tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type
mwheel ns-win ucs-normalize term/common-win tool-bar dnd fontset image
regexp-opt fringe tabulated-list newcomment elisp-mode lisp-mode
prog-mode register page menu-bar rfn-eshadow timer select scroll-bar
mouse jit-lock font-lock syntax facemenu font-core frame 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 charscript case-table epa-hook
jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice
loaddefs button faces cus-face macroexp files text-properties overlay
sha1 md5 base64 format env code-pages mule custom widget
hashtable-print-readable backquote kqueue cocoa ns multi-tty
make-network-process emacs)

Memory information:
((conses 16 196504 7744)
(symbols 48 19533 0)
(miscs 40 68 160)
(strings 32 15110 5660)
(string-bytes 1 445077)
(vectors 16 32924)
(vector-slots 8 651358 5744)
(floats 8 163 155)
(intervals 56 245 20)
(buffers 976 20))

[-- Attachment #2.1: Type: text/html, Size: 6388 bytes --]

[-- Attachment #2.2: 1.png --]
[-- Type: image/png, Size: 41048 bytes --]

[-- Attachment #2.3: 2.png --]
[-- Type: image/png, Size: 38734 bytes --]

[-- Attachment #2.4: Screen Shot 2016-08-19 at 16.51.52.png --]
[-- Type: image/png, Size: 41257 bytes --]

             reply	other threads:[~2016-08-20  0:42 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-20  0:42 Jiajian Huang [this message]
2016-08-20  6:56 ` bug#24271: 25.1; font-lock problem of c++-mode Eli Zaretskii
     [not found]   ` <1645ABE9-D61A-4DDE-B4D6-94A29A2CC2AA@gmail.com>
2016-08-20  7:52     ` Eli Zaretskii
2016-08-20  7:57     ` Jiajian Huang
2016-08-20  8:15       ` Eli Zaretskii
2016-08-20  8:27         ` Jiajian Huang
2016-08-20  8:36           ` Eli Zaretskii
2019-11-17  7:08       ` Lars Ingebrigtsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7756A5F1-342F-4F55-8D6B-1A41B528DE5A@gmail.com \
    --to=wherejoystarts@gmail.com \
    --cc=24271@debbugs.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).