question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Export data for underline

See original GitHub issue

Based on https://github.com/lvgl/lvgl/issues/1618#issuecomment-651403534

FreeType can tell where to place the underline of a text and how thick it should be. See here.

It’d be great to add this info to the font descriptors like this:


/*Initialize a public general font descriptor*/
lv_font_t lv_font_montserrat_12 = {
    .get_glyph_dsc = lv_font_get_glyph_dsc_fmt_txt,    /*Function pointer to get glyph's data*/
    .get_glyph_bitmap = lv_font_get_bitmap_fmt_txt,    /*Function pointer to get glyph's bitmap*/
    .line_height = 15,          /*The maximum line height required by the font*/
    .base_line = 3,             /*Baseline measured from the bottom of the line*/
#if !(LVGL_VERSION_MAJOR == 6 && LVGL_VERSION_MINOR == 0)
    .subpx = LV_FONT_SUBPX_NONE,
#endif
#if LV_VERSION_CHECK(7, 2, 0)
    .underline_ofs = 3,
    .underline_tickness = 2,
#endif
    .dsc = &font_dsc           /*The custom font data. Will be accessed by `get_glyph_bitmap/dsc` */
};

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:24 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
puzrincommented, Jul 27, 2020

released 1.1.0

1reaction
puzrincommented, Jun 30, 2020

How does this work when fonts are mixed? Do we just use the values from the first font (like the other metrics)?

Yes, metrics of first font will be prefered. The same for ascent/descent and so on.

Font mixing is to create new fonts from icons, or to add some icons into font. If anyone wish to merge different text fonts - good luck 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Solved: Power BI Service allows to export only text column...
Power BI Service allows to export only text columns in underline data export functionality ... We have just noticed that not all columns...
Read more >
How can I export data fields and it appear in same format?
How can I export data fields and it appear in same format? In some text fields I underline words or color some words,...
Read more >
When exporting Excel, I have underlined characters in ...
I am going to try VBA to extract it because of my time with MS Access (underlines the whole field) and get the...
Read more >
Is it possible to preserve italics, bold, and underline formatting ...
Currently no. The Excel file created is actually a CSV file, so there is no formatting preserved. What needs to be done is...
Read more >
Export to Excel - Remove underlined text header - MSDN
Web Forms Data Controls ... I would like to see in Export Excel no text underlined in Columns: UserID | FName | LName...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found