Fabric.js: Setting textAlign on a per line basis

Created on 27 Sep 2016  Â·  13Comments  Â·  Source: fabricjs/fabric.js

I would like to set separate text align for every line of a text/iText/textbox object.

possible_feature

Most helpful comment

you cannot define "set separate text align for each line" as Expected Behaviour.
This is a feature request not a bug.

All 13 comments

you cannot define "set separate text align for each line" as Expected Behaviour.
This is a feature request not a bug.

Is this feature has been developed?
This feature is very very very useful.

No, and is not on my priority list.
We do not have a way to define a per line style.
This could be done, but i m unsure of the usuefullness.
I can see it would open opportunities on er line text alignment and indentation and bullets/numbering.
Unsure what else.

Very sad :(
I think this feature is on high demand by many developers…

On Mar 15, 2018, at 6:55 PM, Andrea Bogazzi notifications@github.com wrote:

No, and is not on my priority list.
We do not have a way to define a per line style.
This could be done, but i m unsure of the usuefullness.
I can see it would open opportunities on er line text alignment and indentation and bullets/numbering.
Unsure what else.

—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/kangax/fabric.js/issues/3290#issuecomment-373579110, or mute the thread https://github.com/notifications/unsubscribe-auth/AFo2OgxWMxh8gi5R9sLlIAu5ZjU9lis7ks5texuhgaJpZM4KHVbH.

Well, one of those many developer could develop it!
PRs are welcome.

I would If knew how or at list what is "responsible" for that… where to dig...

On Mar 15, 2018, at 8:34 PM, Andrea Bogazzi notifications@github.com wrote:

Well, one of those many developer could develop it!
PRs are welcome.

—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/kangax/fabric.js/issues/3290#issuecomment-373593610, or mute the thread https://github.com/notifications/unsubscribe-auth/AFo2Om_FG3nuhSUQRnQBzLwRcg2nq044ks5tezLRgaJpZM4KHVbH.

Well there is no such a feature at all.
It must be built from scratch.

Make sense… Where would you started to dig? You know FabriJS better then I… Maybe some function which “responsible” for lines rendering or something like that….?

On Mar 16, 2018, at 5:08 AM, Andrea Bogazzi notifications@github.com wrote:

Well there is no such a feature at all.
It must be built from scratch.

—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/kangax/fabric.js/issues/3290#issuecomment-373694392, or mute the thread https://github.com/notifications/unsubscribe-auth/AFo2Oq3nz4GfVg7pZwcPUH3pXwpRoKnpks5te6tJgaJpZM4KHVbH.

Hi,

I’m trying to create an element with textAlignment per line / paragraph.
Could you please take a look on my issue and propose a solution for that?
https://stackoverflow.com/questions/49329895/fabricjs-how-to-catch-enter-key-pressed https://stackoverflow.com/questions/49329895/fabricjs-how-to-catch-enter-key-pressed
Thank you.

On Mar 16, 2018, at 7:20 AM, Eugene Vilder vilder.eugene@gmail.com wrote:

Make sense… Where would you started to dig? You know FabriJS better then I… Maybe some function which “responsible” for lines rendering or something like that….?

On Mar 16, 2018, at 5:08 AM, Andrea Bogazzi <[email protected] notifications@github.com> wrote:

Well there is no such a feature at all.
It must be built from scratch.

—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/kangax/fabric.js/issues/3290#issuecomment-373694392, or mute the thread https://github.com/notifications/unsubscribe-auth/AFo2Oq3nz4GfVg7pZwcPUH3pXwpRoKnpks5te6tJgaJpZM4KHVbH.

is it solved?
I need this function too....
if not, where is the line or function I start to dig?

someone started a pr but the review did not go far, there is an open pr that is a good start for the feature

Is there workaround for this issue ?

There is an open pr ( now closed by the stale box ) someone should pick up the open PR, start from there and be collaborative in the code review.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

eddieyangtx picture eddieyangtx  Â·  5Comments

keanass picture keanass  Â·  5Comments

semiadam picture semiadam  Â·  3Comments

medialwerk picture medialwerk  Â·  5Comments

f987002856 picture f987002856  Â·  3Comments