Did I find the right examples for you? yes no

All Samples(2)  |  Call(0)  |  Derive(0)  |  Import(2)
int(x=0) -> int or long
int(x, base=10) -> int or long

Convert a number or string to an integer, or return 0 if no arguments
are given.  If x is floating point, the conversion truncates towards zero.
If x is outside the integer range, the function returns a long instead.

If x is not a number or if base is given, then x must be a string or
Unicode object representing an integer literal in the given base.  The
literal can be preceded by '+' or '-' and be surrounded by whitespace.(more...)

src/d/j/django-dash-0.4.4/src/dash/contrib/plugins/news/forms.py   django-dash(Download)
from dash.base import DashboardPluginFormBase
from dash.widgets import BooleanRadioSelect
from dash.contrib.plugins.news.defaults import DEFAULT_MAX_NEWS_ITEMS, DEFAULT_TRUNCATE_AFTER, DEFAULT_CACHE_FOR
from dash.contrib.plugins.rss_feed.defaults import DEFAULT_SHOW_TITLE
 
        ("show_title", DEFAULT_SHOW_TITLE),
        ("max_items", DEFAULT_MAX_NEWS_ITEMS),
        ("truncate_after", DEFAULT_TRUNCATE_AFTER),
        ("cache_for", DEFAULT_CACHE_FOR)
    ]
    show_title = forms.BooleanField(label=_("Show title?"), required=False, initial=DEFAULT_SHOW_TITLE, \
                                    widget=BooleanRadioSelect)
    max_items = forms.IntegerField(label=_("Max feed items to show"), required=True, initial=DEFAULT_MAX_NEWS_ITEMS)
    truncate_after = forms.IntegerField(label=_("Truncate after"), required=False, initial=DEFAULT_TRUNCATE_AFTER)

src/d/j/django-dash-HEAD/src/dash/contrib/plugins/news/forms.py   django-dash(Download)
from dash.base import DashboardPluginFormBase
from dash.widgets import BooleanRadioSelect
from dash.contrib.plugins.news.defaults import DEFAULT_MAX_NEWS_ITEMS, DEFAULT_TRUNCATE_AFTER, DEFAULT_CACHE_FOR
from dash.contrib.plugins.rss_feed.defaults import DEFAULT_SHOW_TITLE
 
        ("show_title", DEFAULT_SHOW_TITLE),
        ("max_items", DEFAULT_MAX_NEWS_ITEMS),
        ("truncate_after", DEFAULT_TRUNCATE_AFTER),
        ("cache_for", DEFAULT_CACHE_FOR)
    ]
    show_title = forms.BooleanField(label=_("Show title?"), required=False, initial=DEFAULT_SHOW_TITLE, \
                                    widget=BooleanRadioSelect)
    max_items = forms.IntegerField(label=_("Max feed items to show"), required=True, initial=DEFAULT_MAX_NEWS_ITEMS)
    truncate_after = forms.IntegerField(label=_("Truncate after"), required=False, initial=DEFAULT_TRUNCATE_AFTER)