Why do font weights sometimes change in cells, where they evolve from a regular weight to a dimmer or lighter font weight? The notebook I have open is not heavy as it only has a few cells. Also, there are no errors occurring with any of the cells.

I noticed this strange behavior when I first started using MMA with version 11.1. I am currently using 13.1 on Windows 10.

Below is a sample of what I am seeing. The top cell shows the regular font I am using. Below is the lightened version that always appears for this cell. It also appears if I copy the code into a new cell. Below that is a copy of the code contained in the lighter cell. Is this a bug?

enter image description here

Here is all the code inside the offending cell.


Options[ReplaceCellStyle] = {"Backup" -> True, "From" -> "Input", 
   "To" -> "Code"};
ReplaceCellStyle[x___?(MatchQ[#, Automatic] &), 
    opts : OptionsPattern[]] /; Length[{x}] <= 1 := 
  With[{f = OptionValue["From"]}, 
   ReplaceCellStyle[Cells[CellStyle -> f], opts]];
ReplaceCellStyle[cells : {__CellObject} | _Cells, 
   opts : OptionsPattern[]] := With[{
   If[Not[TrueQ[checkpass[cells]]], Return[$Failed]];
   backup[cells, FilterRules[{opts}, Options[backup]]];
   replace[cells, FilterRules[{opts}, Options[replace]]];

1 Answer 1


I figured out the problem. Somewhere along the way it picked up bad formatting. It can be cleared by selecting Cell then with menu item: Format -> Clear Formatting.


Not the answer you're looking for? Browse other questions tagged or ask your own question.