Use one font for `mathcal`, but another font for general math (ConTeXt)












3















I want to use (for example) Tex Gyre Heros Math for mathcal, but (for example) Tex Gyre Pagella Math in general for mathematics.
(Why did I want to do that, because Pagella's mathcal seems quite illegible to me.)
I guess the keyword uppercasescript (resp. lowercasescript) for definefontfallback is related for my purpose, but definefontfallback obviously does not fit the situation.



For concreteness, consider that I use



definefontfeature [default] [default] [onum=yes]
definefontfamily [MainFace] [rm] [TeX Gyre Pagella]
definefontfamily [MainFace] [ss] [TeX Gyre Heros]
definefontfamily [MainFace] [tt] [TeX Gyre Cursor] [features=none]
definefontfamily [MainFace] [mm] [Tex Gyre Pagella Math]
setupbodyfont [MainFace, 12pt]


But if replace the above line by (merely according to my guess)



definefontfamily [MainFace] [mm] [Tex Gyre Pagella Math]
definefontfamily [MainFace] [mm] [Tex Gyre Heros Math] [range=uppercasescript]


That doesn't work; Tex Heros is used throughout










share|improve this question





























    3















    I want to use (for example) Tex Gyre Heros Math for mathcal, but (for example) Tex Gyre Pagella Math in general for mathematics.
    (Why did I want to do that, because Pagella's mathcal seems quite illegible to me.)
    I guess the keyword uppercasescript (resp. lowercasescript) for definefontfallback is related for my purpose, but definefontfallback obviously does not fit the situation.



    For concreteness, consider that I use



    definefontfeature [default] [default] [onum=yes]
    definefontfamily [MainFace] [rm] [TeX Gyre Pagella]
    definefontfamily [MainFace] [ss] [TeX Gyre Heros]
    definefontfamily [MainFace] [tt] [TeX Gyre Cursor] [features=none]
    definefontfamily [MainFace] [mm] [Tex Gyre Pagella Math]
    setupbodyfont [MainFace, 12pt]


    But if replace the above line by (merely according to my guess)



    definefontfamily [MainFace] [mm] [Tex Gyre Pagella Math]
    definefontfamily [MainFace] [mm] [Tex Gyre Heros Math] [range=uppercasescript]


    That doesn't work; Tex Heros is used throughout










    share|improve this question



























      3












      3








      3








      I want to use (for example) Tex Gyre Heros Math for mathcal, but (for example) Tex Gyre Pagella Math in general for mathematics.
      (Why did I want to do that, because Pagella's mathcal seems quite illegible to me.)
      I guess the keyword uppercasescript (resp. lowercasescript) for definefontfallback is related for my purpose, but definefontfallback obviously does not fit the situation.



      For concreteness, consider that I use



      definefontfeature [default] [default] [onum=yes]
      definefontfamily [MainFace] [rm] [TeX Gyre Pagella]
      definefontfamily [MainFace] [ss] [TeX Gyre Heros]
      definefontfamily [MainFace] [tt] [TeX Gyre Cursor] [features=none]
      definefontfamily [MainFace] [mm] [Tex Gyre Pagella Math]
      setupbodyfont [MainFace, 12pt]


      But if replace the above line by (merely according to my guess)



      definefontfamily [MainFace] [mm] [Tex Gyre Pagella Math]
      definefontfamily [MainFace] [mm] [Tex Gyre Heros Math] [range=uppercasescript]


      That doesn't work; Tex Heros is used throughout










      share|improve this question
















      I want to use (for example) Tex Gyre Heros Math for mathcal, but (for example) Tex Gyre Pagella Math in general for mathematics.
      (Why did I want to do that, because Pagella's mathcal seems quite illegible to me.)
      I guess the keyword uppercasescript (resp. lowercasescript) for definefontfallback is related for my purpose, but definefontfallback obviously does not fit the situation.



      For concreteness, consider that I use



      definefontfeature [default] [default] [onum=yes]
      definefontfamily [MainFace] [rm] [TeX Gyre Pagella]
      definefontfamily [MainFace] [ss] [TeX Gyre Heros]
      definefontfamily [MainFace] [tt] [TeX Gyre Cursor] [features=none]
      definefontfamily [MainFace] [mm] [Tex Gyre Pagella Math]
      setupbodyfont [MainFace, 12pt]


      But if replace the above line by (merely according to my guess)



      definefontfamily [MainFace] [mm] [Tex Gyre Pagella Math]
      definefontfamily [MainFace] [mm] [Tex Gyre Heros Math] [range=uppercasescript]


      That doesn't work; Tex Heros is used throughout







      fonts context math-fonts






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited Mar 21 at 8:29







      Aminopterin

















      asked Mar 20 at 12:35









      AminopterinAminopterin

      38619




      38619






















          1 Answer
          1






          active

          oldest

          votes


















          5














          When you use the definefontfamily command to set the font for your document you can use definefallbackfamily to set replacements for certain characters.



          One problem in your original question is that you try to load TeX Gyre Heros Math which doesn’t exist and as a result nothing will be replaced.



          definefontfamily     [MainFace] [rm] [TeX Gyre Pagella]
          definefallbackfamily [MainFace] [mm] [TeX Gyre DejaVu Math] [force=yes,range=lowercasescript]
          definefontfamily [MainFace] [mm] [TeX Gyre Pagella Math]

          setupbodyfont [MainFace, 12pt]

          starttext
          m{abc mathscript abc}
          stoptext





          share|improve this answer
























          • Btw, how do I find what font has been installed within the standard TeX Live, at least a list of TeX Gyre fonts, and math fonts? Like you saw, I Googled the name Heros, but did not know there is no Heros Math.

            – Aminopterin
            Mar 21 at 8:11






          • 1





            @Aminopterin you can use mtxrun --script fonts --list --all to list all fonts on your system. You can even filter the results using --pattern=, e.g. mtxrun --script fonts --list --pattern='*Gyre* '--all will give you all TeX Gyre fonts on your system.

            – DG'
            Mar 21 at 10:13












          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "85"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: false,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: null,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f480474%2fuse-one-font-for-mathcal-but-another-font-for-general-math-context%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          5














          When you use the definefontfamily command to set the font for your document you can use definefallbackfamily to set replacements for certain characters.



          One problem in your original question is that you try to load TeX Gyre Heros Math which doesn’t exist and as a result nothing will be replaced.



          definefontfamily     [MainFace] [rm] [TeX Gyre Pagella]
          definefallbackfamily [MainFace] [mm] [TeX Gyre DejaVu Math] [force=yes,range=lowercasescript]
          definefontfamily [MainFace] [mm] [TeX Gyre Pagella Math]

          setupbodyfont [MainFace, 12pt]

          starttext
          m{abc mathscript abc}
          stoptext





          share|improve this answer
























          • Btw, how do I find what font has been installed within the standard TeX Live, at least a list of TeX Gyre fonts, and math fonts? Like you saw, I Googled the name Heros, but did not know there is no Heros Math.

            – Aminopterin
            Mar 21 at 8:11






          • 1





            @Aminopterin you can use mtxrun --script fonts --list --all to list all fonts on your system. You can even filter the results using --pattern=, e.g. mtxrun --script fonts --list --pattern='*Gyre* '--all will give you all TeX Gyre fonts on your system.

            – DG'
            Mar 21 at 10:13
















          5














          When you use the definefontfamily command to set the font for your document you can use definefallbackfamily to set replacements for certain characters.



          One problem in your original question is that you try to load TeX Gyre Heros Math which doesn’t exist and as a result nothing will be replaced.



          definefontfamily     [MainFace] [rm] [TeX Gyre Pagella]
          definefallbackfamily [MainFace] [mm] [TeX Gyre DejaVu Math] [force=yes,range=lowercasescript]
          definefontfamily [MainFace] [mm] [TeX Gyre Pagella Math]

          setupbodyfont [MainFace, 12pt]

          starttext
          m{abc mathscript abc}
          stoptext





          share|improve this answer
























          • Btw, how do I find what font has been installed within the standard TeX Live, at least a list of TeX Gyre fonts, and math fonts? Like you saw, I Googled the name Heros, but did not know there is no Heros Math.

            – Aminopterin
            Mar 21 at 8:11






          • 1





            @Aminopterin you can use mtxrun --script fonts --list --all to list all fonts on your system. You can even filter the results using --pattern=, e.g. mtxrun --script fonts --list --pattern='*Gyre* '--all will give you all TeX Gyre fonts on your system.

            – DG'
            Mar 21 at 10:13














          5












          5








          5







          When you use the definefontfamily command to set the font for your document you can use definefallbackfamily to set replacements for certain characters.



          One problem in your original question is that you try to load TeX Gyre Heros Math which doesn’t exist and as a result nothing will be replaced.



          definefontfamily     [MainFace] [rm] [TeX Gyre Pagella]
          definefallbackfamily [MainFace] [mm] [TeX Gyre DejaVu Math] [force=yes,range=lowercasescript]
          definefontfamily [MainFace] [mm] [TeX Gyre Pagella Math]

          setupbodyfont [MainFace, 12pt]

          starttext
          m{abc mathscript abc}
          stoptext





          share|improve this answer













          When you use the definefontfamily command to set the font for your document you can use definefallbackfamily to set replacements for certain characters.



          One problem in your original question is that you try to load TeX Gyre Heros Math which doesn’t exist and as a result nothing will be replaced.



          definefontfamily     [MainFace] [rm] [TeX Gyre Pagella]
          definefallbackfamily [MainFace] [mm] [TeX Gyre DejaVu Math] [force=yes,range=lowercasescript]
          definefontfamily [MainFace] [mm] [TeX Gyre Pagella Math]

          setupbodyfont [MainFace, 12pt]

          starttext
          m{abc mathscript abc}
          stoptext






          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Mar 20 at 16:59









          Wolfgang SchusterWolfgang Schuster

          5,9161811




          5,9161811













          • Btw, how do I find what font has been installed within the standard TeX Live, at least a list of TeX Gyre fonts, and math fonts? Like you saw, I Googled the name Heros, but did not know there is no Heros Math.

            – Aminopterin
            Mar 21 at 8:11






          • 1





            @Aminopterin you can use mtxrun --script fonts --list --all to list all fonts on your system. You can even filter the results using --pattern=, e.g. mtxrun --script fonts --list --pattern='*Gyre* '--all will give you all TeX Gyre fonts on your system.

            – DG'
            Mar 21 at 10:13



















          • Btw, how do I find what font has been installed within the standard TeX Live, at least a list of TeX Gyre fonts, and math fonts? Like you saw, I Googled the name Heros, but did not know there is no Heros Math.

            – Aminopterin
            Mar 21 at 8:11






          • 1





            @Aminopterin you can use mtxrun --script fonts --list --all to list all fonts on your system. You can even filter the results using --pattern=, e.g. mtxrun --script fonts --list --pattern='*Gyre* '--all will give you all TeX Gyre fonts on your system.

            – DG'
            Mar 21 at 10:13

















          Btw, how do I find what font has been installed within the standard TeX Live, at least a list of TeX Gyre fonts, and math fonts? Like you saw, I Googled the name Heros, but did not know there is no Heros Math.

          – Aminopterin
          Mar 21 at 8:11





          Btw, how do I find what font has been installed within the standard TeX Live, at least a list of TeX Gyre fonts, and math fonts? Like you saw, I Googled the name Heros, but did not know there is no Heros Math.

          – Aminopterin
          Mar 21 at 8:11




          1




          1





          @Aminopterin you can use mtxrun --script fonts --list --all to list all fonts on your system. You can even filter the results using --pattern=, e.g. mtxrun --script fonts --list --pattern='*Gyre* '--all will give you all TeX Gyre fonts on your system.

          – DG'
          Mar 21 at 10:13





          @Aminopterin you can use mtxrun --script fonts --list --all to list all fonts on your system. You can even filter the results using --pattern=, e.g. mtxrun --script fonts --list --pattern='*Gyre* '--all will give you all TeX Gyre fonts on your system.

          – DG'
          Mar 21 at 10:13


















          draft saved

          draft discarded




















































          Thanks for contributing an answer to TeX - LaTeX Stack Exchange!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2ftex.stackexchange.com%2fquestions%2f480474%2fuse-one-font-for-mathcal-but-another-font-for-general-math-context%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Biblatex bibliography style without URLs when DOI exists (in Overleaf with Zotero bibliography)

          ComboBox Display Member on multiple fields

          Is it possible to collect Nectar points via Trainline?