Bir paragrafı temsil eden öğe. Paragraph
öğesi Equation
, Footnote
, Horizontal
, Inline
, Inline
, Page
ve Text
öğeleri içerebilir. Belge yapısı hakkında daha fazla bilgi için Google Dokümanlar'ı genişletme kılavuzuna bakın.
Paragraphs
yeni satır karakterleri içeremez. Yeni satır karakterleri ("\n") satır sonu karakterlerine ("\r") dönüştürülür.
const body = DocumentApp.getActiveDocument().getActiveTab().asDocumentTab().getBody(); // Append a tab header paragraph. const header = body.appendParagraph('A Document'); header.setHeading(DocumentApp.ParagraphHeading.HEADING1); // Append a section header paragraph. const section = body.appendParagraph('Section 1'); section.setHeading(DocumentApp.ParagraphHeading.HEADING2); // Append a regular paragraph. body.appendParagraph('This is a typical paragraph.');
Yöntemler
Yöntem | Dönüş türü | Kısa açıklama |
---|---|---|
add | Positioned | Belirtilen resim blob'undan yeni bir Positioned oluşturup ekler. |
append | Horizontal | Yeni bir Horizontal oluşturup ekler. |
append | Inline | Belirtilen resim blob'undan yeni bir Inline oluşturup ekler. |
append | Inline | Belirtilen Inline değerini ekler. |
append | Page | Yeni bir Page oluşturup ekler. |
append | Page | Belirtilen Page değerini ekler. |
append | Text | Belirtilen içeriklerle yeni bir Text öğesi oluşturup ekler. |
append | Text | Belirtilen Text öğesini ekler. |
clear() | Paragraph | Öğenin içeriğini temizler. |
copy() | Paragraph | Geçerli öğenin ayrılmış, derin bir kopyasını döndürür. |
edit | Text | Düzenlemek için mevcut öğenin Text sürümünü alır. |
find | Range | Öğenin içeriğini, belirtilen türün bir alt öğesi için arar. |
find | Range | Belirtilen Range öğesinden başlayarak öğenin içeriğini, belirtilen türün bir alt öğesi için arar. |
find | Range | Normal ifadeleri kullanarak öğenin içeriğinde belirtilen metin kalıbını arar. |
find | Range | Belirli bir arama sonucundan başlayarak öğenin içeriğini belirtilen metin kalıbıyla arar. |
get | Horizontal | Horizontal öğesini alır. |
get | Object | Öğenin özelliklerini alır. |
get | Element | Belirtilen alt öğe dizininde alt öğeyi alır. |
get | Integer | Belirtilen alt öğenin alt öğe dizini döndürülür. |
get | Paragraph | Paragraph öğesini alır. |
get | Number | Son girintiyi nokta cinsinden alır. |
get | Number | İlk satır girintisini puan cinsinden alır. |
get | Number | Başlangıç girintisini alır. |
get | Number | Satır aralığını nokta cinsinden alır. |
get | String | Bağlantı URL'sini alır. |
get | Element | Öğenin sonraki kardeş öğesini alır. |
get | Integer | Çocuk sayısını alır. |
get | Container | Öğenin üst öğesini alır. |
get | Positioned | Resmin kimliğine göre bir Positioned alır. |
get | Positioned | Paragrafa sabitlenmiş tüm Positioned nesnelerini alır. |
get | Element | Öğenin önceki kardeş öğesini alır. |
get | Number | Öğeden sonraki boşluğu, punto cinsinden alır. |
get | Number | Öğeden önceki boşluğu punto cinsinden alır. |
get | String | Öğenin içeriğini metin dizesi olarak alır. |
get | Text | Metin hizalamasını alır. |
get | Element | Öğenin Element değerini alır. |
insert | Horizontal | Belirtilen dizinde bir Horizontal oluşturup ekler. |
insert | Inline | Belirtilen resim blob'undan yeni bir Inline oluşturup belirtilen dizinde ekler. |
insert | Inline | Belirtilen Inline öğesini belirtilen dizin içine ekler. |
insert | Page | Belirtilen dizinde yeni bir Page oluşturup ekler. |
insert | Page | Belirtilen Page öğesini belirtilen dizin içine ekler. |
insert | Text | Belirtilen dizinde yeni bir metin öğesi oluşturur ve ekler. |
insert | Text | Belirtilen Text öğesini, belirtilen metin içeriğiyle birlikte belirtilen dizinde ekler. |
is | Boolean | Öğenin Document 'ün sonunda olup olmadığını belirler. |
is | Boolean | Soldan sağa ayarını alır. |
merge() | Paragraph | Öğeyi, aynı türdeki önceki kardeş öğeyle birleştirir. |
remove | Paragraph | Belirtilen alt öğeyi kaldırır. |
remove | Paragraph | Öğeyi üst öğesinden kaldırır. |
remove | Boolean | Resmin kimliğine göre bir Positioned kaldırır. |
replace | Element | Normal ifadeler kullanılarak belirli bir metin kalıbının tüm örnekleri belirli bir değiştirme dizesiyle değiştirilir. |
set | Paragraph | Horizontal değerini belirler. |
set | Paragraph | Öğenin özelliklerini ayarlar. |
set | Paragraph | Paragraph değerini belirler. |
set | Paragraph | Son girintiyi nokta cinsinden ayarlar. |
set | Paragraph | İlk satır girintisini nokta cinsinden ayarlar. |
set | Paragraph | Başlangıç girintisini nokta cinsinden ayarlar. |
set | Paragraph | Soldan sağa ayarını belirler. |
set | Paragraph | Satır aralığını, ara vermek için kullanılacak satır sayısını belirten bir miktar olarak ayarlar. |
set | Paragraph | Bağlantı URL'sini ayarlar. |
set | Paragraph | Öğeden sonraki boşluğu punto cinsinden ayarlar. |
set | Paragraph | Öğeden önceki boşluğu punto cinsinden ayarlar. |
set | void | Paragrafın içeriğini metin olarak ayarlar. |
set | Paragraph | Metin hizalamasını ayarlar. |
Ayrıntılı dokümanlar
addPositionedImage(image)
Belirtilen resim blob'undan yeni bir Positioned
oluşturup ekler.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the first paragraph from the body. const paragraph = body.getParagraphs()[0]; // Fetches the specified image URL. const image = UrlFetchApp.fetch( 'https://fonts.gstatic.com/s/i/productlogos/apps_script/v10/web-24dp/logo_apps_script_color_1x_web_24dp.png', ); // Adds the image to the tab, anchored to the first paragraph. paragraph.addPositionedImage(image);
Parametreler
Ad | Tür | Açıklama |
---|---|---|
image | Blob | Resim verileri. |
Return
Positioned
: Yeni konumlandırılmış resim.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
appendHorizontalRule()
Yeni bir Horizontal
oluşturup ekler.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the first paragraph from the body. const paragraph = body.getParagraphs()[0]; // Adds a horizontal line under the first paragraph. paragraph.appendHorizontalRule();
Return
Horizontal
: Yeni yatay kural.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
appendInlineImage(image)
Belirtilen resim blob'undan yeni bir Inline
oluşturup ekler.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the first paragraph from the body. const paragraph = body.getParagraphs()[0]; // Fetches the image from the specified image URL. const image = UrlFetchApp.fetch( 'https://fonts.gstatic.com/s/i/productlogos/apps_script/v10/web-96dp/logo_apps_script_color_1x_web_96dp.png', ); // Adds the image to the first paragraph. paragraph.appendInlineImage(image);
Parametreler
Ad | Tür | Açıklama |
---|---|---|
image | Blob | Resim verileri. |
Return
Inline
: Eklenmiş resim.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
appendInlineImage(image)
Belirtilen Inline
değerini ekler.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the first paragraph from the body. const paragraph = body.getParagraphs()[0]; // Makes a copy of the first image in the body. const image = body.getImages()[0].copy(); // Adds the image to the first paragraph. paragraph.appendInlineImage(image);
Parametreler
Ad | Tür | Açıklama |
---|---|---|
image | Inline | Resim verileri. |
Return
Inline
: Eklenmiş resim.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
appendPageBreak()
Yeni bir Page
oluşturup ekler.
Not: Page
, Table
içinde yer alamaz.
Mevcut öğe bir tablo hücresindeyse bir istisna atılır.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the first paragraph from the body. const paragraph = body.getParagraphs()[0]; // Adds a page break after the first paragraph. paragraph.appendPageBreak();
Return
Page
: Yeni sayfa sonu öğesi.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
appendPageBreak(pageBreak)
Belirtilen Page
değerini ekler.
Not: Page
, Table
içinde bulunamaz.
Geçerli öğe bir tablo hücresinde varsa komut dosyası bir istisna oluşturur.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the first paragraph from the body. const paragraph = body.getParagraphs()[0]; // Adds a page break after the first paragraph. const pageBreak = paragraph.appendPageBreak(); // Makes a copy of the page break. const newPageBreak = pageBreak.copy(); // Adds the copied page break to the paragraph. paragraph.appendPageBreak(newPageBreak);
Parametreler
Ad | Tür | Açıklama |
---|---|---|
page | Page | Eklenecek sayfa sonu. |
Return
Page
: Eklenen sayfa sonu öğesi.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
appendText(text)
Belirtilen içeriklerle yeni bir Text
öğesi oluşturup ekler.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the first paragraph from the body. const paragraph = body.getParagraphs()[0]; // Adds a string to the paragraph. paragraph.appendText('This is a new sentence.');
Parametreler
Ad | Tür | Açıklama |
---|---|---|
text | String | Metin içerikleri. |
Return
Text
: Yeni metin öğesi.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
appendText(text)
Belirtilen Text
öğesini ekler.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the text from the first paragraph in the body. const paragraph1 = body.getParagraphs()[0]; const text = paragraph1.getText(); // Gets the third paragraph in the body. const paragraph3 = body.getParagraphs()[2]; // Adds the text from the first paragraph to the third paragraph. paragraph3.appendText(text);
Parametreler
Ad | Tür | Açıklama |
---|---|---|
text | Text | Eklenecek metin öğesi. |
Return
Text
: Eklenen metin öğesi.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
clear()
copy()
Geçerli öğenin ayrılmış, derin bir kopyasını döndürür.
Öğede bulunan tüm alt öğeler de kopyalanır. Yeni öğenin üst öğesi yok.
Return
Paragraph
: Yeni kopya.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
editAsText()
Düzenlemek için mevcut öğenin Text
sürümünü alır.
Öğe içeriklerini zengin metin olarak değiştirmek için edit
öğesini kullanın. edit
modu, metin olmayan öğeleri (Inline
ve Horizontal
gibi) yoksayar.
Silinen bir metin aralığının tamamına sahip alt öğeler öğeden kaldırılır.
const body = DocumentApp.getActiveDocument().getActiveTab().asDocumentTab().getBody(); // Insert two paragraphs separated by a paragraph containing an // horizontal rule. body.insertParagraph(0, 'An editAsText sample.'); body.insertHorizontalRule(0); body.insertParagraph(0, 'An example.'); // Delete " sample.\n\n An" removing the horizontal rule in the process. body.editAsText().deleteText(14, 25);
Return
Text
: Mevcut öğenin metin sürümü
findElement(elementType)
Öğenin içeriğini, belirtilen türün bir alt öğesi için arar.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
element | Element | Aranacak öğe türü. |
Return
Range
: Arama öğesinin konumunu belirten bir arama sonucu.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
findElement(elementType, from)
Belirtilen Range
öğesinden başlayarak öğenin içeriğini, belirtilen türün bir alt öğesi için arar.
const body = DocumentApp.getActiveDocument().getActiveTab().asDocumentTab().getBody(); // Define the search parameters. let searchResult = null; // Search until the paragraph is found. while ( (searchResult = body.findElement( DocumentApp.ElementType.PARAGRAPH, searchResult, ))) { const par = searchResult.getElement().asParagraph(); if (par.getHeading() === DocumentApp.ParagraphHeading.HEADING1) { // Found one, update and stop. par.setText('This is the first header.'); break; } }
Parametreler
Ad | Tür | Açıklama |
---|---|---|
element | Element | Aranacak öğe türü. |
from | Range | Arama yapılacak arama sonucu. |
Return
Range
: Arama öğesinin sonraki konumunu gösteren bir arama sonucu.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
findText(searchPattern)
Normal ifadeleri kullanarak öğenin içeriğinde belirtilen metin kalıbını arar.
JavaScript normal ifade özelliklerinin bir alt kümesi (ör. yakalama grupları ve mod değiştiriciler) tam olarak desteklenmez.
Sağlanan normal ifade kalıbı, geçerli öğede bulunan her metin bloğuyla bağımsız olarak eşleştirilir.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
search | String | aranacak kalıp |
Return
Range
: Arama metninin konumunu gösteren bir arama sonucudur veya eşleşme yoksa null değerini alır.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
findText(searchPattern, from)
Belirli bir arama sonucundan başlayarak öğenin içeriğini belirtilen metin kalıbıyla arar.
JavaScript normal ifade özelliklerinin bir alt kümesi (ör. yakalama grupları ve mod değiştiriciler) tam olarak desteklenmez.
Sağlanan normal ifade kalıbı, geçerli öğede bulunan her metin bloğuyla bağımsız olarak eşleştirilir.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
search | String | aranacak kalıp |
from | Range | Arama yapılacak arama sonucu |
Return
Range
: Arama metninin sonraki konumunu gösteren bir arama sonucudur veya eşleşme yoksa null değerini alır.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getAlignment()
Horizontal
öğesini alır.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Gets the first paragraph from the body. const paragraph = body.getParagraphs()[0]; // Sets the horizontal alignment to left for the first paragraph. paragraph.setAlignment(DocumentApp.HorizontalAlignment.LEFT); // Gets the horizontal alignment of the first paragraph and logs it to the // console. console.log(paragraph.getAlignment().toString());
Return
Horizontal
: Hizalama.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getAttributes()
Öğenin özelliklerini alır.
Sonuç, her geçerli öğe özelliği için bir özellik içeren bir nesnedir. Bu nesnedeki her özellik adı, Document
dizininde bir öğeye karşılık gelir.
const doc = DocumentApp.getActiveDocument(); const documentTab = doc.getActiveTab().asDocumentTab(); const body = documentTab.getBody(); // Append a styled paragraph. const par = body.appendParagraph('A bold, italicized paragraph.'); par.setBold(true); par.setItalic(true); // Retrieve the paragraph's attributes. const atts = par.getAttributes(); // Log the paragraph attributes. for (const att in atts) { Logger.log(`${att}:${atts[att]}`); }
Return
Object
: Öğenin özellikleri.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getChild(childIndex)
Belirtilen alt öğe dizininde alt öğeyi alır.
const body = DocumentApp.getActiveDocument().getActiveTab().asDocumentTab().getBody(); // Obtain the first element in the tab. const firstChild = body.getChild(0); // If it's a paragraph, set its contents. if (firstChild.getType() === DocumentApp.ElementType.PARAGRAPH) { firstChild.asParagraph().setText('This is the first paragraph.'); }
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Integer | Alınacak alt öğenin dizini. |
Return
Element
: Belirtilen dizindeki alt öğe.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getChildIndex(child)
Belirtilen alt öğenin alt öğe dizini döndürülür.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Element | Dizininin alınacağı alt öğe. |
Return
Integer
: Alt dizin.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getHeading()
Paragraph
öğesini alır.
// Opens the Docs file by its ID. If you created your script from within // a Google Docs file, you can use DocumentApp.getActiveDocument() instead. // TODO(developer): Replace the ID with your own. const doc = DocumentApp.openById('123abc'); // Gets the body contents of the tab by its ID. // TODO(developer): Replace the ID with your own. const body = doc.getTab('123abc').asDocumentTab().getBody(); // Adds a paragraph to the body. const paragraph = body.appendParagraph('Title heading'); // Sets the paragraph heading style to 'Title.' paragraph.setHeading(DocumentApp.ParagraphHeading.TITLE); // Gets the heading style and logs it to the console. console.log(paragraph.getHeading().toString());
Return
Paragraph
: Başlık.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getIndentEnd()
Son girintiyi nokta cinsinden alır.
Return
Number
: Bitiş girintisi (noktalar cinsinden)
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getIndentFirstLine()
İlk satır girintisini puan cinsinden alır.
Return
Number
: ilk satır girintisi (noktalar cinsinden)
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getIndentStart()
Başlangıç girintisini alır.
Return
Number
: Başlangıç girintisi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getLineSpacing()
Satır aralığını nokta cinsinden alır.
Return
Number
: Satır aralığı (punto cinsinden)
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getLinkUrl()
Bağlantı URL'sini alır.
Return
String
: Bağlantı URL'si veya öğe bu özellik için birden fazla değer içeriyorsa null
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getNextSibling()
Öğenin sonraki kardeş öğesini alır.
Bir sonraki kardeş öğe, aynı üst öğeye sahiptir ve geçerli öğeyi takip eder.
Return
Element
: Sonraki kardeş öğe.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getNumChildren()
Çocuk sayısını alır.
const body = DocumentApp.getActiveDocument().getActiveTab().asDocumentTab().getBody(); // Log the number of elements in the tab. Logger.log(`There are ${body.getNumChildren()} elements in the tab's body.`);
Return
Integer
: Çocuk sayısı.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getParent()
Öğenin üst öğesini alır.
Üst öğe, geçerli öğeyi içerir.
Return
Container
: Üst öğe.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getPositionedImage(id)
Resmin kimliğine göre bir Positioned
alır.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
id | String | resim kimliği |
Return
Positioned
: Konumlandırılmış resim
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getPositionedImages()
Paragrafa sabitlenmiş tüm Positioned
nesnelerini alır.
Return
Positioned
: Yerleştirilmiş resimlerin listesi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getPreviousSibling()
Öğenin önceki kardeş öğesini alır.
Önceki kardeş öğe, aynı üst öğeye sahiptir ve geçerli öğeden önce gelir.
Return
Element
: Önceki kardeş öğe.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getSpacingAfter()
Öğeden sonraki boşluğu, punto cinsinden alır.
Return
Number
: Öğeden sonraki aralık (punto cinsinden)
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getSpacingBefore()
Öğeden önceki boşluğu punto cinsinden alır.
Return
Number
: Öğeden önceki boşluk (punto cinsinden)
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getText()
Öğenin içeriğini metin dizesi olarak alır.
Return
String
: Öğenin metin dizesi olarak içeriği
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getTextAlignment()
Metin hizalamasını alır. Kullanılabilir hizalama türleri Document
, Document
ve Document
'dir.
Return
Text
: Metin hizalamasının türü veya metin birden fazla metin hizası türü içeriyorsa ya da metin hizası hiç ayarlanmadıysa null
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
getType()
Öğenin Element
değerini alır.
Belirli bir öğenin tam türünü belirlemek için get
öğesini kullanın.
const doc = DocumentApp.getActiveDocument(); const documentTab = doc.getActiveTab().asDocumentTab(); const body = documentTab.getBody(); // Obtain the first element in the active tab's body. const firstChild = body.getChild(0); // Use getType() to determine the element's type. if (firstChild.getType() === DocumentApp.ElementType.PARAGRAPH) { Logger.log('The first element is a paragraph.'); } else { Logger.log('The first element is not a paragraph.'); }
Return
Element
: Öğe türü.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
insertHorizontalRule(childIndex)
Belirtilen dizinde bir Horizontal
oluşturup ekler.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Integer | Öğenin ekleneceği dizin |
Return
Horizontal
: yeni yatay kural öğesi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
insertInlineImage(childIndex, image)
Belirtilen resim blob'undan yeni bir Inline
oluşturup belirtilen dizinde ekler.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Integer | Öğenin ekleneceği dizin |
image | Blob | resim verileri |
Return
Inline
: Eklenen satır içi resim öğesi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
insertInlineImage(childIndex, image)
Belirtilen Inline
öğesini belirtilen dizin içine ekler.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Integer | Öğenin ekleneceği dizin |
image | Inline | resim verileri |
Return
Inline
: Eklenen satır içi resim öğesi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
insertPageBreak(childIndex)
Belirtilen dizinde yeni bir Page
oluşturup ekler.
Not: Page
, Table
içinde yer alamaz.
Mevcut öğe bir tablo hücresindeyse bir istisna atılır.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Integer | Öğenin ekleneceği dizin |
Return
Page
: yeni sayfa sonu öğesi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
insertPageBreak(childIndex, pageBreak)
Belirtilen Page
öğesini belirtilen dizin içine ekler.
Not: Page
, Table
içinde yer alamaz.
Mevcut öğe bir tablo hücresindeyse bir istisna atılır.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Integer | Öğenin ekleneceği dizin |
page | Page | eklenecek sayfa sonu |
Return
Page
: Eklenen sayfa sonu öğesi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
insertText(childIndex, text)
Belirtilen dizinde yeni bir metin öğesi oluşturur ve ekler.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Integer | Öğenin ekleneceği dizin |
text | String | metin içerikleri |
Return
Text
: Yeni metin öğesi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
insertText(childIndex, text)
Belirtilen Text
öğesini, belirtilen metin içeriğiyle birlikte belirtilen dizinde ekler.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Integer | Öğenin ekleneceği dizin |
text | Text | eklenecek metin öğesi |
Return
Text
: Eklenen metin öğesi
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
isAtDocumentEnd()
Öğenin Document
'ün sonunda olup olmadığını belirler.
Return
Boolean
: Öğenin sekmenin sonunda olup olmadığı.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
isLeftToRight()
Soldan sağa ayarını alır.
Return
Boolean
: soldan sağa ayar
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
merge()
Öğeyi, aynı türdeki önceki kardeş öğeyle birleştirir.
Yalnızca aynı Element
öğeleri birleştirilebilir. Geçerli öğede bulunan tüm alt öğeler, önceki kardeş öğeye taşınır.
Mevcut öğe dokümandan kaldırılır.
const doc = DocumentApp.getActiveDocument(); const documentTab = doc.getActiveTab().asDocumentTab(); const body = documentTab.getBody(); // Example 1: Merge paragraphs // Append two paragraphs to the document's active tab. const par1 = body.appendParagraph('Paragraph 1.'); const par2 = body.appendParagraph('Paragraph 2.'); // Merge the newly added paragraphs into a single paragraph. par2.merge(); // Example 2: Merge table cells // Create a two-dimensional array containing the table's cell contents. const cells = [ ['Row 1, Cell 1', 'Row 1, Cell 2'], ['Row 2, Cell 1', 'Row 2, Cell 2'], ]; // Build a table from the array. const table = body.appendTable(cells); // Get the first row in the table. const row = table.getRow(0); // Get the two cells in this row. const cell1 = row.getCell(0); const cell2 = row.getCell(1); // Merge the current cell into its preceding sibling element. const merged = cell2.merge();
Return
Paragraph
: Birleştirilmiş öğe.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
removeChild(child)
Belirtilen alt öğeyi kaldırır.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
child | Element | Kaldırılacak alt öğe |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
removeFromParent()
Öğeyi üst öğesinden kaldırır.
const doc = DocumentApp.getActiveDocument(); const documentTab = doc.getActiveTab().asDocumentTab(); const body = documentTab.getBody(); // Remove all images in the active tab's body. const imgs = body.getImages(); for (let i = 0; i < imgs.length; i++) { imgs[i].removeFromParent(); }
Return
Paragraph
: Kaldırılan öğe.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
removePositionedImage(id)
Resmin kimliğine göre bir Positioned
kaldırır.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
id | String | resim kimliği |
Return
Boolean
: Belirtilen resmin kaldırılıp kaldırılmadığı
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
replaceText(searchPattern, replacement)
Normal ifadeler kullanılarak belirli bir metin kalıbının tüm örnekleri belirli bir değiştirme dizesiyle değiştirilir.
Arama kalıbı, JavaScript normal ifade nesnesi değil, dize olarak iletilir. Bu nedenle, kalıptaki tüm ters eğik çizgileri koddan çıkarmanız gerekir.
Bu yöntem, desteklenen söz dizimini sınırlayan Google'ın RE2 normal ifade kitaplığını kullanır.
Sağlanan normal ifade kalıbı, geçerli öğede bulunan her metin bloğuyla bağımsız olarak eşleştirilir.
const body = DocumentApp.getActiveDocument().getActiveTab().asDocumentTab().getBody(); // Clear the text surrounding "Apps Script", with or without text. body.replaceText('^.*Apps ?Script.*$', 'Apps Script');
Parametreler
Ad | Tür | Açıklama |
---|---|---|
search | String | Aranacak normal ifade kalıbı |
replacement | String | Değişim olarak kullanılacak metin |
Return
Element
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setAlignment(alignment)
Horizontal
değerini belirler.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
alignment | Horizontal | yatay hizalama |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setAttributes(attributes)
Öğenin özelliklerini ayarlar.
Belirtilen attributes parametresi, her bir özellik adının Document
numaralandırmasında bir öğe olduğu ve her bir özellik değerinin uygulanacak yeni değer olduğu bir nesne olmalıdır.
const doc = DocumentApp.getActiveDocument(); const documentTab = doc.getActiveTab().asDocumentTab(); const body = documentTab.getBody(); // Define a custom paragraph style. const style = {}; style[DocumentApp.Attribute.HORIZONTAL_ALIGNMENT] = DocumentApp.HorizontalAlignment.RIGHT; style[DocumentApp.Attribute.FONT_FAMILY] = 'Calibri'; style[DocumentApp.Attribute.FONT_SIZE] = 18; style[DocumentApp.Attribute.BOLD] = true; // Append a plain paragraph. const par = body.appendParagraph('A paragraph with custom style.'); // Apply the custom style. par.setAttributes(style);
Parametreler
Ad | Tür | Açıklama |
---|---|---|
attributes | Object | Öğenin özellikleri. |
Return
Paragraph
: Geçerli öğe.
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setHeading(heading)
Paragraph
değerini belirler.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
heading | Paragraph | başlık |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setIndentEnd(indentEnd)
Son girintiyi nokta cinsinden ayarlar.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
indent | Number | Bitiş girintisi (noktalar cinsinden) |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setIndentFirstLine(indentFirstLine)
İlk satır girintisini nokta cinsinden ayarlar.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
indent | Number | ilk satır girintisi (noktalar cinsinden) |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setIndentStart(indentStart)
Başlangıç girintisini nokta cinsinden ayarlar.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
indent | Number | Başlangıç girintisi (noktalar cinsinden) |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setLeftToRight(leftToRight)
Soldan sağa ayarını belirler.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
left | Boolean | soldan sağa ayarını |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setLineSpacing(multiplier)
Satır aralığını, ara vermek için kullanılacak satır sayısını belirten bir miktar olarak ayarlar.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
multiplier | Number | satır sayısı |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setLinkUrl(url)
Bağlantı URL'sini ayarlar.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
url | String | bağlantı URL'si |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setSpacingAfter(spacingAfter)
Öğeden sonraki boşluğu punto cinsinden ayarlar.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
spacing | Number | Öğeden sonraki aralık (punto cinsinden) |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setSpacingBefore(spacingBefore)
Öğeden önceki boşluğu punto cinsinden ayarlar.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
spacing | Number | Öğeden önceki boşluk (punto cinsinden) |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setText(text)
Paragrafın içeriğini metin olarak ayarlar.
Not: Mevcut içerikler silinir.
Parametreler
Ad | Tür | Açıklama |
---|---|---|
text | String | yeni metin içerikleri |
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents
setTextAlignment(textAlignment)
Metin hizalamasını ayarlar. Kullanılabilir hizalama türleri Document
, Document
ve Document
'dir.
// Make the entire first paragraph in the active tab be superscript. const documentTab = DocumentApp.getActiveDocument().getActiveTab().asDocumentTab(); const text = documentTab.getBody().getParagraphs()[0].editAsText(); text.setTextAlignment(DocumentApp.TextAlignment.SUPERSCRIPT);
Parametreler
Ad | Tür | Açıklama |
---|---|---|
text | Text | uygulanacak metin hizalamasının türü |
Return
Paragraph
: Geçerli öğe
Yetkilendirme
Bu yöntemi kullanan komut dosyalarının aşağıdaki kapsamlardan bir veya daha fazlası için yetkilendirilmesi gerekir:
-
https://www.googleapis.com/auth/documents.currentonly
-
https://www.googleapis.com/auth/documents