reference/xlswriter/xlsx-format/italic.xml
547a556ea0ffcae65a07fba5eac97f6f5c4faf2c
...
...
@@ -42,7 +42,7 @@
42
42
<refsect1 role="examples">
43
43
&reftitle.examples;
44
44
<example>
45
-
<title>example</title>
45
+
<title>Italic style example</title>
46
46
<programlisting role="php">
47
47
<![CDATA[
48
48
<?php
...
...
@@ -50,14 +50,13 @@ $config = [
50
50
'path' => './tests'
51
51
];
52
52

53
-
$excel = new \Vtiful\Kernel\Excel($config);
53
+
$excel = new \Vtiful\Kernel\Excel($config);
54
+
$excel->fileName('tutorial01.xlsx');
54
55

55
-
$fileObject = $excel->fileName('tutorial01.xlsx');
56
-
$fileHandle = $fileObject->getHandle();
56
+
$format = new \Vtiful\Kernel\Format($excel->getHandle());
57
+
$italicStyle = $format->italic()->toResource();
57
58

58
-
$italicStyle = \Vtiful\Kernel\Format::italic($fileHandle);
59
-

60
-
$fileObject->header(['name', 'age'])
59
+
$excel->header(['name', 'age'])
61
60
->data([['viest', 21]])
62
61
->setColumn('A:A', 200, $italicStyle)
63
62
->output();
64
63