PhpSpreadsheet
PhpSpreadsheet copied to clipboard
Font location on Ubuntu servers are not correct
This is:
- [ x ] a bug report
- [ ] a feature request
- [ ] **not** a usage question (ask them on https://stackoverflow.com/questions/tagged/phpspreadsheet or https://gitter.im/PHPOffice/PhpSpreadsheet)
What is the expected behavior?
When using Excel file with i.e. Calibri, it should find the installed font, when it is installed on /usr/share/fonts/truetype/vista/calibri.ttf. All truetype fonts installed on our server at least, are installed grouped by directories.
What is the current behavior?
It cannot find the font. And the reason is pretty obvious. $fontFile = self::$trueTypeFontPath . $fontFile;. It makes no effort to look in sub-directories.
What are the steps to reproduce?
Set true-type font directory to /usr/share/fonts/truetype/ as the documentation states, and try to use it.
What features do you think are causing the issue
- [ ] Reader
- [ ] Writer
- [ ] Styles
- [ ] Data Validations
- [ ] Formula Calulations
- [ ] Charts
- [ ] AutoFilter
- [ ] Form Elements
- [ x ] Fonts
I may submit a pull request on this later, but I just wanted to register the issue for now.