Class SolidFill
Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
SolidFill
Isian warna solid.
Objek SolidFill
terpisah dan tidak dapat diubah, sehingga tidak mencerminkan perubahan yang dilakukan setelah
dibuat.
Metode
Metode | Jenis hasil yang ditampilkan | Deskripsi singkat |
getAlpha() | Number | Dapatkan opasitas warna, dalam interval dari [0, 1.0], dengan 1.0 berarti sepenuhnya buram. |
getColor() | Color | Mendapatkan warna isian. |
Dokumentasi mendetail
getAlpha()
Dapatkan opasitas warna, dalam interval dari [0, 1.0], dengan 1.0 berarti sepenuhnya buram.
Pulang pergi
Number
Otorisasi
Skrip yang menggunakan metode ini memerlukan otorisasi dengan satu atau beberapa cakupan berikut:
-
https://www.googleapis.com/auth/presentations.currentonly
-
https://www.googleapis.com/auth/presentations
getColor()
Mendapatkan warna isian.
Pulang pergi
Color
Otorisasi
Skrip yang menggunakan metode ini memerlukan otorisasi dengan satu atau beberapa cakupan berikut:
-
https://www.googleapis.com/auth/presentations.currentonly
-
https://www.googleapis.com/auth/presentations
Kecuali dinyatakan lain, konten di halaman ini dilisensikan berdasarkan Lisensi Creative Commons Attribution 4.0, sedangkan contoh kode dilisensikan berdasarkan Lisensi Apache 2.0. Untuk mengetahui informasi selengkapnya, lihat Kebijakan Situs Google Developers. Java adalah merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2025-07-26 UTC.
[null,null,["Terakhir diperbarui pada 2025-07-26 UTC."],[[["\u003cp\u003e\u003ccode\u003eSolidFill\u003c/code\u003e represents a solid color fill used in Google Slides, and these objects are immutable, meaning they won't change after creation.\u003c/p\u003e\n"],["\u003cp\u003eYou can get the opacity of the fill using \u003ccode\u003egetAlpha()\u003c/code\u003e, which returns a number between 0 and 1, where 1 is fully opaque.\u003c/p\u003e\n"],["\u003cp\u003eThe \u003ccode\u003egetColor()\u003c/code\u003e method allows you to retrieve the color of the fill as a \u003ccode\u003eColor\u003c/code\u003e object.\u003c/p\u003e\n"],["\u003cp\u003eTo use these methods, your script needs authorization with specific scopes related to Google Presentations.\u003c/p\u003e\n"]]],[],null,["# Class SolidFill\n\nSolidFill\n\nA solid color fill.\n\n\n`Solid``Fill` objects are detached and immutable, so do not reflect changes made after\nthey have been created. \n\n### Methods\n\n| Method | Return type | Brief description |\n|---------------------------|----------------------------------------------|----------------------------------------------------------------------------------------------|\n| [getAlpha()](#getAlpha()) | `Number` | Get the opacity of the color, in the interval from \\[0, 1.0\\], where 1.0 means fully opaque. |\n| [getColor()](#getColor()) | [Color](/apps-script/reference/slides/color) | Get the color of the fill. |\n\nDetailed documentation\n----------------------\n\n### `get``Alpha()`\n\nGet the opacity of the color, in the interval from \\[0, 1.0\\], where 1.0 means fully opaque.\n\n#### Return\n\n\n`Number`\n\n#### Authorization\n\nScripts that use this method require authorization with one or more of the following [scopes](/apps-script/concepts/scopes#setting_explicit_scopes):\n\n- `https://www.googleapis.com/auth/presentations.currentonly`\n- `https://www.googleapis.com/auth/presentations`\n\n*** ** * ** ***\n\n### `get``Color()`\n\nGet the color of the fill.\n\n#### Return\n\n\n[Color](/apps-script/reference/slides/color)\n\n#### Authorization\n\nScripts that use this method require authorization with one or more of the following [scopes](/apps-script/concepts/scopes#setting_explicit_scopes):\n\n- `https://www.googleapis.com/auth/presentations.currentonly`\n- `https://www.googleapis.com/auth/presentations`"]]