activiti-rest process diagram can't show chinese character well?

cancel
Showing results for 
Search instead for 
Did you mean: 
dylanblue
Active Member

activiti-rest process diagram can't show chinese character well?

when I access the restful api: runtime/process-instance/{process-instanceid}}/diagram

why the diagram can't display Chinese character well?how to fixed it ? thanks.

so does the app-admin war.

5 Replies
salaboy
Senior Member

Re: activiti-rest process diagram can't show chinese character well?

There might be several problems here. 

Which version are you using? 

One problem might be the default encoding of the JVM where you are running activiti. Are you changing the encoding? 

Can you check which encoding are you using? 

dylanblue
Active Member

Re: activiti-rest process diagram can't show chinese character well?

the version is 6.0.0

I didn't change the default encoding of the jvm;

but the activiti-app can display chinese well in web page.

i have searched on the internet that it may be the default font problem.

can you tell me how to configure the font name when the process diagram generated?

salaboy
Senior Member

Re: activiti-rest process diagram  can't show chinese character well?

Hi Dylan, that's probably in this project: Activiti/modules/activiti-image-generator at 6.x · Activiti/Activiti · GitHub 

Not sure if the font is configurable, but that sounds like a great community contribution. 

Hope that helps. 

dylanblue
Active Member

Re: activiti-rest process diagram  can't show chinese character well?

I have found the source code to change font name.but it's not configurable.

I have just change the font name from "Arial " to "宋体" in the class "

ProcessEngineConfiguration".

Thank you for advice.

salaboy
Senior Member

Re: activiti-rest process diagram  can't show chinese character well?

We will appreciate if you submit a PR with your fix to our Github repo, so other community members can benefit from that, it is also good to boost your community profile Smiley Happy