PINE LIBRARY

easytable

Library "easytable"
Create tables easily, with minimal code    
 ▦ FEATURES ▦                    
█ Create tables █ JSON To Table █ Change Colors █ Array to Rows/Columns █ Pre-Styles █ Change Text Size █ Delete Rows/Columns █ Blink Cells

                 

indentify_table_id() Identifies all tables ID number in each cell(0,0).

get_table_by_id(id_number) Get table object by ID number.
  Parameters:
    id_number: (int) ID number of the table to fetch.
  Returns: table.

change_cells_color(table_object, cells_color, start_column, end_column, start_row, end_row) Change cells background colors.
  Parameters:
    table_object: (table) table object to be changed.
    cells_color: (color) Cells color.
    start_column: (int) Start column.
    end_column: (int) End column.
    start_row: (int) Start Row.
    end_row: (int) End Row to change.
  Returns: Void.

change_cells_text_color(table_object, text_color, start_column, end_column, start_row, end_row) Change cells text colors.
  Parameters:
    table_object: (table) table object to be changed.
    text_color: (color) Text color.
    start_column: (int) Start column.
    end_column: (int) End column.
    start_row: (int) Start Row.
    end_row: (int) End Row.
  Returns: Void.

change_all_table_text_color(table_object, text_color, table_column_size, table_row_size) Change All table text color.
  Parameters:
    table_object: (table) table object to be changed.
    text_color: (color) Text color.
    table_column_size: (int) Size of the table columns.
    table_row_size: (int) Size of the table rows.
  Returns: Void.

change_table_size(table_object, n_of_columns, n_of_rows, tbl_size) Change table size.
  Parameters:
    table_object: (table) table object to be changed.
    n_of_columns: (int) Size of the table columns.
    n_of_rows: (int) Size of the table rows.
    tbl_size: (string) size of the table.
  Returns: Void.

change_cells_text_size(text_size, start_column, end_column, start_row, end_row, table_id) Change table cells text size .
  Parameters:
    text_size: (string) Text size.
    start_column: (int) Start column.
    end_column: (int)(optional) End column.
    start_row: (int)(optional) Start Row.
    end_row: (int)(optional) End Row.
    table_id: (int)(optional) Number of the ID of the table.
  Returns: Void.

table_delete_row(table_object, table_column_size, start_row, end_row) Delete specified rows from table.
  Parameters:
    table_object: (table) table object to be changed.
    table_column_size: (int) Table columns max size.
    start_row: (int) Start row to delete.
    end_row: (int)(optional) End row to delete (optional — Assumes start_row value).
  Returns: Void.

table_delete_column(table_object, table_row_size, start_column, end_column) Delete specified columns from table.
  Parameters:
    table_object: (table) table object to be changed.
    table_row_size: (int) Table rows max size.
    start_column: (int) Start column to delete.
    end_column: (int)(optional) End column to delete (optional — Assumes start_column value).
  Returns: Void.

array_to_table_column_auto(column_to_insert, array_to_insert, table_id) Insert string array to table column without passing table object.
  Parameters:
    column_to_insert: (int) Column to be inserted.
    array_to_insert: (string array) Start column to delete.
    table_id: (int)(optional) Number of the ID of the table.
  Returns: Void.

array_to_table_row_auto(row_to_insert, array_to_insert, table_id) Insert string array to table row without passing table object.
  Parameters:
    row_to_insert: (int) Column to be inserted.
    array_to_insert: (string array) Start column to delete.
    table_id: (int)(optional) Number of the ID of the table.
  Returns: Void.

array_to_table_row(table_object, row_to_insert, array_to_insert) Insert string array to table row by passing table object.
  Parameters:
    table_object: (table) table object to be changed.
    row_to_insert: (int) Row to be inserted.
    array_to_insert: (string array) Start column to delete.
  Returns: Void.

array_to_table_column(table_object, column_to_insert, array_to_insert) Insert string array to table column by passing table object.
  Parameters:
    table_object: (table) table object to be changed.
    column_to_insert: (int) Column to be inserted.
    array_to_insert: (string array) Start column to delete.
  Returns: Void.

blink_cell(cell_column, cell_row, c_color, blink_interval_ms, table_id) Changes cell color at set intervals (blink).
  Parameters:
    cell_column: (int) Cell column position.
    cell_row: (int) Cell row position.
    c_color: (color) Color to blink.
    blink_interval_ms: (int)(opt) Interval in milliseconds.
    table_id: (int)(opt) Table ID number.

change_table_style(table_object, number_of_columns, number_of_rows, color) Changes table pre-style by selecting a pre-style number.
  Parameters:
    table_object: (table) table object to be changed.
    number_of_columns: (int) Table column size.
    number_of_rows: (int) Table row size.
    color: 1 (color) Color of .
  Returns: Void.

create_table_clean(n_of_columns, n_of_rows, position) Create a simple(blank) table without any styling.
  Parameters:
    n_of_columns: (int) Numbers of columns in the table.
    n_of_rows: (int) Number of rows in the table.
    position: (string) table position.
  Returns: table object.

create_table_with_style(n_of_columns, n_of_rows, style_number, position) Create table with a pre-set style.
  Parameters:
    n_of_columns: (int) Numbers of columns in the table.
    n_of_rows: (int) Number of rows in the table.
    style_number: (int) Style number.
    position: (string) table position.
  Returns: table object.

json_to_table(raw_json) Create table based on input raw json string.
  Parameters:
    raw_json: (int) Raw json string.
  Returns: table object.

json_example() Example function that display a table based on a json

example_create_table()
colorscreatetabledebuggingdisplayeasytablejsontablejsontotabletabletabledata

Perpustakaan Pine

Dalam semangat sebenar TradingView, penulis telah menerbitkan kod Pine ini sebagai satu perpustakaan sumber terbuka supaya pengaturcara Pine lain dari komuniti kami boleh menggunakannya semula. Sorakan kepada penulis! Anda boleh menggunakan perpustakaan ini secara peribadi atau dalam penerbitan sumber terbuka lain, tetapi penggunaan semula kod dalam penerbitan ini adalah dikawal oleh Peraturan dalaman.

Penafian