# No docs for figure attributes in Makie

**URL:** <https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683>\
**Category:** Visualization\
**Tags:** makie\
**Created:** [August 19, 2021, 4:38pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683 "2021-08-19T16:38:00Z")\
**Posts on this page:** 13\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gregstrq](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gregstrq/32/20620_2.png) [@Gregstrq](https://discourse.julialang.org/u/Gregstrq)\
**Post date:** [August 19, 2021, 4:38pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/1 "2021-08-19T16:38:00Z")

</div>

Hi, guys.  
I have decided to give `Makie.jl` a try and prepare the plots for my paper in it.

Unfortunately, I got stuck at the very beginning.  
Skimming over docs, I noticed that there is no list of the figure attributes which are available for adjustment. The docs only mention the resolution attribute, which is quite misleading.

- If I use `CairoMakie.jl` backend to produce high-quality vector plots, what does resolution specify? Surely, it can’t be the resolution of the figure in this case, right (cause it is vector graphics)?
- How do I set up the size of the figure? Can I do that not only in points, but also in inches, cantimeters, etc.?
- Is there somewhere a full list of Figure attributes? May be I missed it.

---

<div class="post-metadata">

**Author:** ![rafael.guerra](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/rafael.guerra/32/216610_2.png) [@rafael.guerra](https://discourse.julialang.org/u/rafael.guerra)\
**Post date:** [August 19, 2021, 4:48pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/2 "2021-08-19T16:48:43Z")

</div>

Check [this post](https://discourse.julialang.org/t/how-to-specify-the-dpi-while-saving-a-makie-figure/66588/2) out for the second question.

---

<div class="post-metadata">

**Author:** ![Gregstrq](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gregstrq/32/20620_2.png) [@Gregstrq](https://discourse.julialang.org/u/Gregstrq)\
**Post date:** [August 19, 2021, 5:22pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/3 "2021-08-19T17:22:56Z")

</div>

It is certainly a solution to my second point. On the other hand, I do not think that it is good that the users of Makie have to think about such details.  
It looks quite easy to add a thin abstraction layer for the physical units and have Makie automatically do the conversion to points or pixels depending on the output format.

What do you think about this idea?

---

<div class="post-metadata">

**Author:** ![jules](https://avatars.discourse-cdn.com/v4/letter/j/41988e/32.png) [@jules](https://discourse.julialang.org/u/jules)\
**Post date:** [August 19, 2021, 7:10pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/4 "2021-08-19T19:10:06Z")

</div>

Cairo uses pt as its internal metric, so with 1in == 72pt you can calculate any size you want. If you have a good idea for an implementation to make this easier, we always appreciate PRs. Both Simon and I don’t have much time currently.

---

<div class="post-metadata">

**Author:** ![hendri54](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/hendri54/32/9621_2.png) [@hendri54](https://discourse.julialang.org/u/hendri54)\
**Post date:** [August 19, 2021, 8:46pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/5 "2021-08-19T20:46:07Z")

</div>

Were you looking for [http://makie.juliaplots.org/stable/generated/plot-attributes.html](http://makie.juliaplots.org/stable/generated/plot-attributes.html)?

---

<div class="post-metadata">

**Author:** ![Gregstrq](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gregstrq/32/20620_2.png) [@Gregstrq](https://discourse.julialang.org/u/Gregstrq)\
**Post date:** [August 19, 2021, 9:57pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/6 "2021-08-19T21:57:23Z")

</div>

The page you referenced lists the attributes of a plot object. The `Axis` attributes are listed [here](http://makie.juliaplots.org/stable/makielayout/reference.html#Makie.MakieLayout.Axis). But I did not find the attributes of `Figure` anywhere. Guess I will have to resort to `fieldnames` to figure it out. Unfortunately, it may be hard to understand what the attribute names mean without an explanation.

---

<div class="post-metadata">

**Author:** ![lazarusA](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/lazarusa/32/6571_2.png) [@lazarusA](https://discourse.julialang.org/u/lazarusA)\
**Post date:** [August 19, 2021, 11:16pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/7 "2021-08-19T23:16:09Z")

</div>

Still not sure what exactly are you asking for, but for `Figure`, we have `backgroundcolor` , `resolution` , `font` and `fontsize` and the [figure\_padding](http://makie.juliaplots.org/stable/figure.html#Figure-padding), that I know of. And you can see how to use them here. [https://juliadatascience.io/attributes.html](https://juliadatascience.io/attributes.html) (Makie in a nutshell, this chapter is still WIP).

---

<div class="post-metadata">

**Author:** ![aramirezreyes](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/aramirezreyes/32/42573_2.png) [@aramirezreyes](https://discourse.julialang.org/u/aramirezreyes)\
**Post date:** [August 20, 2021, 6:06am UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/8 "2021-08-20T06:06:31Z")

</div>

I agree with @Gregstrq that the documentation should show the possible attributes that can be passed to the `Figure()` constructor that are not plot or axis attributes. I tried finding it but didn’t succeed. Maybe all of those for the underlying scene

```julia
    scene_attributes = (
        :backgroundcolor,
        :resolution,
        :show_axis,
        :show_legend,
        :scale_plot,
        :center,
        :axis,
        :axis2d,
        :axis3d,
        :legend,
        :camera,
        :limits,
        :padding,
        :raw,
        :SSAO
    ))

```

plus all of those related to theming plots and layoutables?

---

<div class="post-metadata">

**Author:** ![Gregstrq](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gregstrq/32/20620_2.png) [@Gregstrq](https://discourse.julialang.org/u/Gregstrq)\
**Post date:** [August 20, 2021, 7:38am UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/9 "2021-08-20T07:38:51Z")

</div>

> [@lazarusA](#):
>
> And you can see how to use them here. [Attributes - Julia Data Science](https://juliadatascience.io/attributes.html)

It would be really nice to have this information available in `Makie.jl` docs. No offense, but it is really counterintuitive to seek the information about `Makie.jl` in the docs of different github organization.

---

<div class="post-metadata">

**Author:** ![lazarusA](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/lazarusa/32/6571_2.png) [@lazarusA](https://discourse.julialang.org/u/lazarusA)\
**Post date:** [August 20, 2021, 8:37am UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/10 "2021-08-20T08:37:41Z")

</div>

It’s a book. So is a different approach. Although, this information comes from the documentation. And, there is plenty of ways to find information nowadays. [Home](http://makie.juliaplots.org/dev/) and from there there is also a link to more examples [https://lazarusa.github.io/BeautifulMakie/](https://lazarusa.github.io/BeautifulMakie/)

---

<div class="post-metadata">

**Author:** ![Gregstrq](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gregstrq/32/20620_2.png) [@Gregstrq](https://discourse.julialang.org/u/Gregstrq)\
**Post date:** [August 20, 2021, 11:53am UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/11 "2021-08-20T11:53:53Z")

</div>

Ok, sorry. I might have sounded a bit irritated. Thank you for giving the links.

I wanted to point out the issue with documentation of `Makie.jl` itself. The list of the attributes for Figures should be somewhere in the documentation, because it is a logical place to look for such information.

I have looked through the documentation an did not find such a list there. Of course, it is possible that I simply missed it. As such, could you point me to a specific place in the official `Makie.jl` documentation, where this list is provided?

---

<div class="post-metadata">

**Author:** ![liuyxpp](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/liuyxpp/32/9870_2.png) [@liuyxpp](https://discourse.julialang.org/u/liuyxpp)\
**Post date:** [August 20, 2021, 11:56am UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/12 "2021-08-20T11:56:33Z")

</div>

It is really strange that there are lists of attributes for Axis and othe types but no Figure’s. I’d also like a list of attributes for Figure.

---

<div class="post-metadata">

**Author:** ![Gregstrq](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/gregstrq/32/20620_2.png) [@Gregstrq](https://discourse.julialang.org/u/Gregstrq)\
**Post date:** [August 20, 2021, 12:12pm UTC](https://discourse.julialang.org/t/no-docs-for-figure-attributes-in-makie/66683/13 "2021-08-20T12:12:16Z")

</div>

Since I am not the only one, who was not able to find the list of attributes for a figure, I have created an [issue](https://github.com/JuliaPlots/Makie.jl/issues/1241).
