Silent hace 6 años
padre
commit
ac384d8e95
Se han modificado 2 ficheros con 3 adiciones y 1 borrados
  1. 3 1
      app/Http/Controllers/Admin/SettingController.php
  2. BIN
      public/fonts/simsun.ttc

+ 3 - 1
app/Http/Controllers/Admin/SettingController.php

xqd
@@ -113,7 +113,9 @@ class SettingController extends Controller
             return $this->showWarning('分享文字位置错误');
         }
 
-        $image = $image->text($text, $pos[0], $pos[1]);
+        $image = $image->text($text, $pos[0], $pos[1], function ($font) {
+            $font->file('fonts/simsun.ttc');
+        });
 
         $size = $image->filesize();
 

BIN
public/fonts/simsun.ttc