javascript - Columns with line-numbers by column-count -


enter image description here

hello,

i've created view css3 "column-count"-property without line numbers. works fine, question how possible add line-numbers such view.

it seems not possible css only.

what solution achieve this?

looking @ question , no code shared - exact answer can not given , time consuming.

here can try for

  1. count total number of character in textual content - paragraph
  2. you need define how many columns text devided into
  3. number of characters or letters each line contain. (this include every character such alpha-numeric + special + blank space)
  4. you can write js count number of characters , print counter value after reaching limit each line.
  5. in way js print line number based on number characters.

example

  1. consider textual content contains 1000 characters
  2. consider each line of column contain 25 characters
  3. which further means have 40 lines (1000/25) of text.
  4. consider there 4 columns
  5. which further means each column have 10 lines
  6. you need consider \n explicitly consider end of line.
  7. once know number lines can run loops , line along row-numbers.

Comments

Popular posts from this blog

OpenCV OpenCL: Convert Mat to Bitmap in JNI Layer for Android -

android - org.xmlpull.v1.XmlPullParserException: expected: START_TAG {http://schemas.xmlsoap.org/soap/envelope/}Envelope -

python - How to remove the Xframe Options header in django? -