text-scale-mode docstring says
The amount of scaling is determined by the variable
text-scale-mode-amount: one step scales the global default
face size by the value of the variable
(a negative amount shrinks the text).
text-scale-set functions may be used to interactively modify
text-scale-mode-amount (they also enable or
disable `text-scale-mode' as necessary)."
So only the default face is affected. Looking at
see this works by setting the variable
Alist of face remappings.
Each element is of the form:
(FACE . REPLACEMENT),
which causes display of the face FACE to use REPLACEMENT instead.
REPLACEMENT is a face specification, i.e. one of the following:
(1) a face name
(2) a property list of attribute/value pairs, or
(3) a list in which each element has the form of (1) or (2).
Indeed if we display this variable value w/o text-scale-mode we see:
face-remapping-alist is a variable defined in ‘C source code’.
Its value is nil
And after having typed
Its value is ((default (:height 1.2) default))
face-remapping-alist seems to work, ie try:
(setq face-remapping-alist '((default (:height 2.4) default)
(italic (:height 2.4) italic)))
The functions used by
text-scale-mode to change
face-remap-remove-relative. We could modify
call them for both
'italic fonts. Alternatively, we
can advise both functions so that a remapping for the
font is added/removed as well. Here's the code to do that:
(defun my/face-remap-add-relative-advice (face &rest specs)
"advice to add remap for italic font"
(if (eq face 'default)
(setq my/italic-cookie (apply #'face-remap-add-relative 'italic specs))))
(defun my/face-remap-remove-relative-advice (cookie)
"advice to remove remap for italic font"
(if (eq (car cookie) 'default)
(advice-add #'face-remap-add-relative :after #'my/face-remap-add-relative-advice)
(advice-add #'face-remap-remove-relative :after #'my/face-remap-remove-relative-advice)
That's a quick hack, it would need more work to handle more fonts, the clean solution may be to change
text-scale-mode so that it can handle any font, but it seems to do what you need.