Skip to content

Commit 2fe5cfc

Browse files
committed
avoid use of layout.axisid.titlefont in ggplotly()
1 parent 1c7b107 commit 2fe5cfc

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

R/ggplotly.R

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -697,8 +697,11 @@ gg2list <- function(p, width = NULL, height = NULL,
697697
gridwidth = unitConvert(panelGrid, "pixels", type),
698698
zeroline = FALSE,
699699
anchor = anchor,
700-
title = faced(axisTitleText, axisTitle$face),
701-
titlefont = text2font(axisTitle)
700+
# layout.axisid.title don't yet support alignment :(
701+
title = list(
702+
text = faced(axisTitleText, axisTitle$face),
703+
font = text2font(axisTitle)
704+
)
702705
)
703706

704707
# set scaleanchor/scaleratio if these are fixed coordinates

0 commit comments

Comments
 (0)