# Bold and italic text styles

**URL:** <https://discourse.processing.org/t/bold-and-italic-text-styles/45586>\
**Category:** Coding Questions\
**Created:** [January 14, 2025, 12:20am UTC](https://discourse.processing.org/t/bold-and-italic-text-styles/45586 "2025-01-14T00:20:37Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gadger](https://avatars.discourse-cdn.com/v4/letter/g/6a8cbe/32.png) [@Gadger](https://discourse.processing.org/u/Gadger)\
**Post date:** [January 14, 2025, 12:20am UTC](https://discourse.processing.org/t/bold-and-italic-text-styles/45586/1 "2025-01-14T00:20:37Z")

</div>

How can I get bold and italic styling for text using the default font? I need the rendered text to be (approximately) the same whether the sketch is run on Windows, Mac or Linux.

---

<div class="post-metadata">

**Author:** ![glv](https://yyz2.discourse-cdn.com/flex036/user_avatar/discourse.processing.org/glv/32/18785_2.png) [@glv](https://discourse.processing.org/u/glv)\
**Post date:** [January 14, 2025, 12:56am UTC](https://discourse.processing.org/t/bold-and-italic-text-styles/45586/2 "2025-01-14T00:56:12Z")

</div>

Hello @Gadger ,

Not sure what the default is.  
You could include a font in your sketch!

Take a look here:

> **[loadFont() / Reference](https://processing.org/reference/loadfont_)**
>
> Loads a .vlw formatted font into a PFont object. Create a .vlw font by selecting "Create Font..." from the Tools menu. This tool creates a texture for each alphanumeric character and then adds …

```auto
PFont myFont;

void setup()
  {
  //printArray(PFont.list());

   size(700, 130);

  myFont = loadFont("Arial-BoldItalicMT-48.vlw");
  textFont(myFont, 32);

  fill(0); // Set text color to black
  text("This is bold and italic text !", 50, 70);
  }

```

 ![image](https://canada1.discourse-cdn.com/flex036/uploads/processingfoundation1/original/3X/0/e/0ebfe652487b59123e14b4a9382a78f7f615069b.png)

`:)`

---

<div class="post-metadata">

**Author:** ![Gadger](https://avatars.discourse-cdn.com/v4/letter/g/6a8cbe/32.png) [@Gadger](https://discourse.processing.org/u/Gadger)\
**Post date:** [January 14, 2025, 6:08pm UTC](https://discourse.processing.org/t/bold-and-italic-text-styles/45586/3 "2025-01-14T18:08:16Z")

</div>

Thanks glv. I can’t find the specification of the default sans-serif font, so I’ll use some open fonts that look similar, along the lines you suggested.
