Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

view.add_representation(repr_type="label", labelType="text", labelText=...) #1047

Open
juliasubbotina opened this issue Jul 10, 2024 · 0 comments

Comments

@juliasubbotina
Copy link

juliasubbotina commented Jul 10, 2024

Hello,--
I am having an issue with labels representation.
My code below does not work if label type is "text". However it works just fine for other types of labels:


view[1].add_representation(repr_type="label", selection=".CA and  70 and :X", 
                           labelType="text", labelText=['ASP 70'],
                              color = "black", fontWeight="bold", radius=6,
                              showBackground = True, xOffset = 0.5 , zOffset =5)

I tries different options for labelText, nothing worked:

labelText= ['ASP 70'] # -- option 1
labelText= 'ASP 70' -- option 2

* @property {String[]} labelText - list of label strings, must set `labelType` to "text"
* to take effect

What would be the correct way to setup labelType="text" representation?

Similar issue was reported in #923

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant