• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Python library.convert_to_intc函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Python中xformslib.library.convert_to_intc函数的典型用法代码示例。如果您正苦于以下问题:Python convert_to_intc函数的具体用法?Python convert_to_intc怎么用?Python convert_to_intc使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了convert_to_intc函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Python代码示例。

示例1: fl_create_bitmap_cursor

def fl_create_bitmap_cursor(source, maskstr, width, height, hotx, hoty):
    """fl_create_bitmap_cursor(source, maskstr, width, height, hotx, hoty)
    -> cursornum

    Creates a bitmap cursor, using cursors other than those defined by
    the standard cursor font.

    Parameters
    ----------
        source : str of ubytes
            bitmap to be used as cursor.
        maskstr : str of ubytes
            bitmap defining the shape of the cursor. The pixels set to 1
            define which source pixels are displayed. If it is empty ("") all
            bits in source are displayed.
        width : int
            width of cursor
        height : int
            height of cursor
        hotx : int
            horizontal hotspot of the cursor (relative to the source origin)
        hoty : int
            vertical hotspot of the cursor (relative to the source origin)

    Returns
    -------
        cursornum : int
            cursor id

    Examples
    --------
        >>> *todo*

    Notes
    -----
        Status: NA-UTest + Doc + Demo = OK

    """
    _fl_create_bitmap_cursor = library.cfuncproto(
        library.load_so_libforms(), "fl_create_bitmap_cursor",
        cty.c_int, [xfdata.STRING, xfdata.STRING, cty.c_int, cty.c_int,
        cty.c_int, cty.c_int],
        """int fl_create_bitmap_cursor(const char * source,
           const char * mask, int w, int h, int hotx, int hoty)""")
    library.check_if_flinitialized()
    s_source = library.convert_to_bytestrc(source)
    if not maskstr:    # if it is empty
        s_maskstr = cty.cast(maskstr, cty.c_void_p)
    else:
        s_maskstr = library.convert_to_bytestrc(maskstr)
    i_width = library.convert_to_intc(width)
    i_height = library.convert_to_FL_Coord(height)
    i_hotx = library.convert_to_intc(hotx)
    i_hoty = library.convert_to_intc(hoty)
    library.keep_elem_refs(source, maskstr, width, height, hotx, hoty, \
            s_source, s_maskstr, i_width, i_height, i_hotx, i_hoty)
    retval = _fl_create_bitmap_cursor(s_source, s_maskstr, i_width, \
            i_height, i_hotx, i_hoty)
    return retval
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:59,代码来源:flcursor.py


示例2: fl_set_pixmap_align

def fl_set_pixmap_align(ptr_flobject, align, xmargin, ymargin):
    """fl_set_pixmap_align(ptr_flobject, align, xmargin, ymargin)

    Changes alignment of a pixmap. By default it is displayed centered
    inside the bounding box; although you can place a pixmap outside of
    the bounding box, it probably is not a good idea.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            pixmap flobject
        align : int
            alignment of pixmap. Values (from xfdata.py)
            - FL_ALIGN_CENTER (In the middle of the box, inside it),
            - FL_ALIGN_TOP (To the top of the box, outside it),
            - FL_ALIGN_BOTTOM (To the bottom of the box, outside it),
            - FL_ALIGN_LEFT (To the left of the box, outside it),
            - FL_ALIGN_RIGHT (To the right of the box, outside it),
            - FL_ALIGN_LEFT_TOP (To the left and top of the box, outside it),
            - FL_ALIGN_RIGHT_TOP (To the right and top of the box, outside it),
            - FL_ALIGN_LEFT_BOTTOM (To the left and bottom of box, outside),
            - FL_ALIGN_RIGHT_BOTTOM (To the right and bottom of box, outside),
            - FL_ALIGN_INSIDE (places the text inside the box),
            - FL_ALIGN_VERT (not functional yet).
            Bitwise OR with FL_ALIGN_INSIDE is allowed.
        xmargin : int
            extra margin to leave in addition to the flobject border
            width. By default it is 3.
        ymargin : int
            extra margin to leave in addition to the flobject border
            height. By default it is 3.

    Examples
    --------
        >>> fl_set_pixmap_align(xpmobj, xfdata.FL_ALIGN_CENTER, 10, 10)

    Notes
    -----
        Status: UnitTest + Doc + Demo = OK

    """
    _fl_set_pixmap_align = library.cfuncproto(
        library.load_so_libforms(), "fl_set_pixmap_align",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int, cty.c_int,
        cty.c_int],
        """void fl_set_pixmap_align(FL_OBJECT * ob, int align,
           int xmargin, int ymargin)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    library.checkfatal_allowed_value_in_list(align, xfdata.ALIGN_list)
    i_align = library.convert_to_intc(align)
    i_xmargin = library.convert_to_intc(xmargin)
    i_ymargin = library.convert_to_intc(ymargin)
    library.keep_elem_refs(ptr_flobject, align, xmargin, ymargin, \
            i_align, i_xmargin, i_ymargin)
    _fl_set_pixmap_align(ptr_flobject, i_align, i_xmargin, i_ymargin)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:56,代码来源:flbitmap.py


示例3: fl_set_chart_baseline

def fl_set_chart_baseline(ptr_flobject, yesno):
    """fl_set_chart_baseline(ptr_flobject, yesno)

    Turns on or off the chart's baseline.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            chart flobject
        yesno : int
            flag for baseline. Values 0 (if disabled) or 1 (if enabled)

    Examples
    --------
        >>> fl_set_chart_baseline(pchrtobj, 1)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_chart_baseline = library.cfuncproto(
        library.load_so_libforms(), "fl_set_chart_baseline",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_chart_baseline(FL_OBJECT * ob, int iYesNo)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_chart_baseline(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:30,代码来源:flchart.py


示例4: fl_set_input_scroll

def fl_set_input_scroll(ptr_flobject, yesno):
    """fl_set_input_scroll(ptr_flobject, yesno)

    Turn on or off scrolling for an input field (for both multiline and
    single line input field).

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            input flobject
        yesno : int
            flag to enable/disable scrolling. Values 0 (disabled) or 1
            (enabled)

    Examples
    --------
        >>> fl_set_input_scroll(pinpobj, 1)

    Notes
    -----
        Status: NA-UTest + NoDoc + NoDemo = Maybe

    """
    _fl_set_input_scroll = library.cfuncproto(
        library.load_so_libforms(),
        "fl_set_input_scroll",
        None,
        [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_input_scroll(FL_OBJECT * ob, int yes)""",
    )
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_input_scroll(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:35,代码来源:flinput.py


示例5: fl_set_chart_autosize

def fl_set_chart_autosize(ptr_flobject, yesno):
    """fl_set_chart_autosize(ptr_flobject, yesno)

    Defines whether the chart should autosize along the x-axis. Normally
    width of the bars and distance between the points in a line-chart are
    normally scaled.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            chart flobject
        yesno : int
            autosize flag. Values 1 (if enabled) or 0 (if disabled).
            If it is set to 0 the width of the bars will be such that the
            maximum number of items fits in the box.

    Examples
    --------
        >>> fl_set_chart_autosize(pchrtobj, 1)

    Notes
    -----
        Status: NA-UTest + Doc + Demo = OK

    """
    _fl_set_chart_autosize = library.cfuncproto(
        library.load_so_libforms(), "fl_set_chart_autosize",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_chart_autosize(FL_OBJECT * ob, int autosize)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_chart_autosize(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:34,代码来源:flchart.py


示例6: fl_set_timer_countup

def fl_set_timer_countup(ptr_flobject, yesno):
    """fl_set_timer_countup(ptr_flobject, yesno)

    Changes timer behavior so the timer counts up and shows elapsed time.
    By default, a timer counts down toward zero and the value shown (for
    xfdata.FL_VALUE_TIMERs) is the time left until the timer expires.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            timer flobject
        yesno : int
            flag to set count up or down. Values 0 (counts down and shows time
            left) or 1 (counts up and shows elapsed time)

    Examples
    --------
        >>> fl_set_timer_countup(ptimerobj, 1)

    Notes
    -----
        Status: NA-UTest + Doc + Demo = OK

    """
    _fl_set_timer_countup = library.cfuncproto(
        library.load_so_libforms(), "fl_set_timer_countup",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_timer_countup(FL_OBJECT * ob, int yes)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_timer_countup(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:33,代码来源:fltimer.py


示例7: fl_set_pixmapbutton_focus_outline

def fl_set_pixmapbutton_focus_outline(ptr_flobject, yesno):
    """fl_set_pixmapbutton_focus_outline(ptr_flobject, yesno)

    Enables or disables the focus outline of the pixmap button.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            button flobject
        yesno : int
            flag to enable (1) or disable (0) the focus outline

    Examples
    --------
        >>> fl_set_pixmapbutton_focus_outline(pmapobj, 1)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_pixmapbutton_focus_outline = library.cfuncproto(
        library.load_so_libforms(), "fl_set_pixmapbutton_focus_outline",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_pixmapbutton_focus_outline(FL_OBJECT * ob, int yes)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_pixmapbutton_focus_outline(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:30,代码来源:flbutton.py


示例8: fl_set_folder_bynumber

def fl_set_folder_bynumber(ptr_flobject, seqnum):
    """fl_set_folder_bynumber(ptr_flobject, seqnum)

    Defines which folder to show by its sequence number.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            tabfolder flobject
        seqnum : int
            sequence number of folder to show. The first tab on the left
            has a sequence number 1, the second 2 etc..

    Examples
    --------
        >>> fl_set_floder_bynumber(ptbfobj, 2)

    Notes
    -----
        Status: NA-UTest + Doc + Demo = OK

    """
    _fl_set_folder_bynumber = library.cfuncproto(
        library.load_so_libforms(), "fl_set_folder_bynumber",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_folder_bynumber(FL_OBJECT * ob, int num)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_seqnum = library.convert_to_intc(seqnum)
    library.keep_elem_refs(ptr_flobject, seqnum, i_seqnum)
    _fl_set_folder_bynumber(ptr_flobject, i_seqnum)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:31,代码来源:fltabfolder.py


示例9: fl_set_canvas_depth

def fl_set_canvas_depth(ptr_flobject, depth):
    """fl_set_canvas_depth(ptr_flobject, depth)

    Defines the depth of canvas flobject. Changing depth does not generally
    make sense once the canvas window is created (which happens when the
    parent form is shown).

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            canvas flobject
        depth : int
            depth value of canvas. Values e.g. 8, 16, 24?, 32, ...

    Examples
    --------
        >>> fl_set_canvas_depth(pcanvobj, 32)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_canvas_depth = library.cfuncproto(
        library.load_so_libforms(), "fl_set_canvas_depth",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_canvas_depth(FL_OBJECT * obj, int depth)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_depth = library.convert_to_intc(depth)
    library.keep_elem_refs(ptr_flobject, depth, i_depth)
    _fl_set_canvas_depth(ptr_flobject, i_depth)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:32,代码来源:flcanvas.py


示例10: fl_set_counter_min_repeat

def fl_set_counter_min_repeat(ptr_flobject, fdelay):
    """fl_set_counter_min_repeat(ptr_flobject, fdelay)

    Defines the final delay of a counter. By default the counter value changes
    first slowly and the rate of change then accelerates until a final speed
    is reached. The default final delay is 50 ms.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            counter flobject
        fdelay : int
            final delay in milliseconds

    Examples
    --------
        >>> fl_set_counter_min_repeat(pcntrobj, 100)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_counter_min_repeat = library.cfuncproto(
        library.load_so_libforms(), "fl_set_counter_min_repeat",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_counter_min_repeat(FL_OBJECT * ob, int millisec)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_fdelay = library.convert_to_intc(fdelay)
    library.keep_elem_refs(ptr_flobject, fdelay, i_fdelay)
    _fl_set_counter_min_repeat(ptr_flobject, i_fdelay)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:32,代码来源:flcounter.py


示例11: fl_set_counter_speedjump

def fl_set_counter_speedjump(ptr_flobject, yesno):
    """fl_set_counter_speedjump(ptr_flobject, yesno)

    Makes only the first change of the counter has a different delay from all
    the following ones. The delay for the first change of the counter value
    will then be the one set by fl_set_counter_repeat() and the following
    delays last as long as set by fl_set_counter_min_repeat().

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            counter flobject
        yesno : int
            flag. Values 1 (to set speedjump) or 0 (to unset speedjump)

    Examples
    --------
        >>> fl_set_counter_speedjump(pcntrobj, 1)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_counter_speedjump = library.cfuncproto(
        library.load_so_libforms(), "fl_set_counter_speedjump",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_counter_speedjump(FL_OBJECT * ob, int yes_no)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_counter_speedjump(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:33,代码来源:flcounter.py


示例12: fl_set_input_cursor_visible

def fl_set_input_cursor_visible(ptr_flobject, yesno):
    """fl_set_input_cursor_visible(ptr_flobject, yesno)

    Turns on or off the cursor of the input field.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            input flobject
        yesno : int
            flag to set/unset cursor visibility. Values 1 (visible) or 0
            (not visible)

    Examples
    --------
        >>> fl_set_input_cursor_visible(pinpobj, 1)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_input_cursor_visible = library.cfuncproto(
        library.load_so_libforms(),
        "fl_set_input_cursor_visible",
        None,
        [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_input_cursor_visible(FL_OBJECT * ob, int visible)""",
    )
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_input_cursor_visible(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:34,代码来源:flinput.py


示例13: fl_set_counter_precision

def fl_set_counter_precision(ptr_flobject, precis):
    """fl_set_counter_precision(ptr_flobject, precis)

    Defines the precision (number of digits after the dot) with which
    the counter value is displayed.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            counter flobject
        precis : int
            precision to be set

    Examples
    --------
        >>> fl_set_counter_precision(pcntrobj, 2)

    Notes
    -----
        Status: NA-UTest + Doc + Demo = OK

    """
    _fl_set_counter_precision = library.cfuncproto(
        library.load_so_libforms(), "fl_set_counter_precision",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_counter_precision(FL_OBJECT * ob, int prec)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_precis = library.convert_to_intc(precis)
    library.keep_elem_refs(ptr_flobject, precis, i_precis)
    _fl_set_counter_precision(ptr_flobject, i_precis)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:31,代码来源:flcounter.py


示例14: fl_set_input_xoffset

def fl_set_input_xoffset(ptr_flobject, offset):
    """fl_set_input_xoffset(ptr_flobject, offset)

    Scrolls programmatically horizontally (to the left).

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            input flobject
        offset : int
            positive number of pixels to scroll to the left relative to the
            nominal position of the text lines.

    Examples
    --------
        >>> *todo*

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_input_xoffset = library.cfuncproto(
        library.load_so_libforms(),
        "fl_set_input_xoffset",
        None,
        [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_input_xoffset(FL_OBJECT * ob, int xoff)""",
    )
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_offset = library.convert_to_intc(offset)
    library.keep_elem_refs(ptr_flobject, offset, i_offset)
    _fl_set_input_xoffset(ptr_flobject, i_offset)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:34,代码来源:flinput.py


示例15: fl_set_input_topline

def fl_set_input_topline(ptr_flobject, linenum):
    """fl_set_input_topline(ptr_flobject, linenum)

    Scrolls vertically an input flobject (for input fields of type
    xfdata.FL_MULTILINE_INPUT only).

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            input flobject
        linenum : int
            the new top line id (starting from 1) in the input field.

    Examples
    --------
        >>> fl_set_input_topline(ptr_flobject, 3)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_input_topline = library.cfuncproto(
        library.load_so_libforms(),
        "fl_set_input_topline",
        None,
        [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_input_topline(FL_OBJECT * ob, int top)""",
    )
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_linenum = library.convert_to_intc(linenum)
    library.keep_elem_refs(ptr_flobject, linenum, i_linenum)
    _fl_set_input_topline(ptr_flobject, i_linenum)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:34,代码来源:flinput.py


示例16: fl_set_input_selected

def fl_set_input_selected(ptr_flobject, yesno):
    """fl_set_input_selected(ptr_flobject, yesno)

    Selects or deselects the current input. It places the cursor at the
    end of the string when selected.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            input flobject
        yesno : int
            flag to deselect/select input. Values 0 (deselected) or 1
            (selected)

    Examples
    --------
        >>> fl_set_input_selected(pinpobj, 1)

    Notes
    -----
        Status: NA-UTest + NoDoc + NoDemo = Maybe

    """
    _fl_set_input_selected = library.cfuncproto(
        library.load_so_libforms(),
        "fl_set_input_selected",
        None,
        [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_input_selected(FL_OBJECT * ob, int yes)""",
    )
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_input_selected(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:35,代码来源:flinput.py


示例17: fl_set_clock_ampm

def fl_set_clock_ampm(ptr_flobject, yesno):
    """fl_set_clock_ampm(ptr_flobject, yesno)

    Switches the display to 12hr system (am-pm). By default, the
    digital clock uses 24hr system.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            clock flobject
        yesno : int
            flag. Values 1 (12hr system used) or 0 (24hr system used)

    Examples
    --------
        >>> fl_set_clock_ampm(pclkobj, 1)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_clock_ampm = library.cfuncproto(
        library.load_so_libforms(), "fl_set_clock_ampm",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_clock_ampm(FL_OBJECT * ob, int y)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_yesno = library.convert_to_intc(yesno)
    library.keep_elem_refs(ptr_flobject, yesno, i_yesno)
    _fl_set_clock_ampm(ptr_flobject, i_yesno)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:31,代码来源:flclock.py


示例18: fl_set_slider_precision

def fl_set_slider_precision(ptr_flobject, precis):
    """fl_set_slider_precision(ptr_flobject, precis)

    Defines the precision which value a valslider is shown with.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            slider flobject
        precis : int
            precision number of shown value after the dot.

    Examples
    --------
        >>> fl_set_slider_precision(sldobj, 3)

    Notes
    -----
        Status: NA-UTest + Doc + Demo = OK

    """
    _fl_set_slider_precision = library.cfuncproto(
        library.load_so_libforms(), "fl_set_slider_precision",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_set_slider_precision(FL_OBJECT * ob, int prec)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_precis = library.convert_to_intc(precis)
    library.keep_elem_refs(ptr_flobject, precis, i_precis)
    _fl_set_slider_precision(ptr_flobject, i_precis)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:30,代码来源:flslider.py


示例19: fl_delete_folder_bynumber

def fl_delete_folder_bynumber(ptr_flobject, seqnum):
    """fl_delete_folder_bynumber(ptr_flobject, seqnum)

    Removes a folder from a tabfolder flobject by its sequence number. After
    deletion, the number of folders in the tabfolder as well as the sequence
    numbers are updated. This means if you want to delete all folders after
    the second folder, you can do that by deleting the third folder repeatedly.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            tabfolder flobject
        seqnum : int
            sequence number of folder to be deleted

    Examples
    --------
        >>> *todo*

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_delete_folder_bynumber = library.cfuncproto(
        library.load_so_libforms(), "fl_delete_folder_bynumber",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_delete_folder_bynumber(FL_OBJECT * ob, int num)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_seqnum = library.convert_to_intc(seqnum)
    library.keep_elem_refs(ptr_flobject, seqnum, i_seqnum)
    _fl_delete_folder_bynumber(ptr_flobject, i_seqnum)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:33,代码来源:fltabfolder.py


示例20: fl_set_slider_repeat

def fl_set_slider_repeat(ptr_flobject, tdelay):
    """fl_set_slider_repeat(ptr_flobject, tdelay)

    Defines the time delay between jumps of the scrollbar knob when the mouse
    button is kept pressed down on the scrollbar outside of the knobs area.
    The delay for the very first jump is twice that long in order to avoid
    jumping to start too soon when only a single click was intended but the
    user is a bit slow in releasing the mouse button.

    Parameters
    ----------
        ptr_flobject : pointer to xfdata.FL_OBJECT
            slider flobject
        tdelay : int
            time delay (in milliseconds) to be set. Default value is 100 ms

    Examples
    --------
        >>> fl_set_slider_repeat(pslobj, 200)

    Notes
    -----
        Status: NA-UTest + Doc + NoDemo = Maybe

    """
    _fl_set_slider_repeat = library.cfuncproto(
        library.load_so_libforms(), "fl_set_slider_repeat",
        None, [cty.POINTER(xfdata.FL_OBJECT), cty.c_int],
        """void fl_get_slider_repeat(FL_OBJECT * obj, int)""")
    library.check_if_flinitialized()
    library.verify_flobjectptr_type(ptr_flobject)
    i_tdelay = library.convert_to_intc(tdelay)
    library.keep_elem_refs(ptr_flobject, tdelay, i_tdelay)
    _fl_set_slider_repeat(ptr_flobject, i_tdelay)
开发者ID:BackupTheBerlios,项目名称:xforms-python-svn,代码行数:34,代码来源:flslider.py



注:本文中的xformslib.library.convert_to_intc函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Python library.keep_elem_refs函数代码示例发布时间:2022-05-26
下一篇:
Python library.check_if_flinitialized函数代码示例发布时间:2022-05-26
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap