예제 #1
0
void Scene::Insert(Interactor* component, IntCoord x, IntCoord y, Alignment a) {
    Interactor* i = Wrap(component);
    PrepareToInsert(i);
    IntCoord ax = x, ay = y;
    DoAlign(i, a, ax, ay);
    DoInsert(i, true, ax, ay);
}
예제 #2
0
void EditorTweaks::OnAlignLast(cb_unused wxCommandEvent& event)
{
    if(!AlignerLastUsed)
        return;

    if (AlignerLastUsedAuto)
        DoAlignAuto();
    else
        DoAlign(AlignerLastUsedIdx);
}
예제 #3
0
void EditorTweaks::OnAlign(wxCommandEvent& event)
{
    int id = event.GetId();
    for ( unsigned int i = 0 ; i < AlignerMenuEntries.size(); i++)
    {
        if ( AlignerMenuEntries[i].id == id )
        {
            DoAlign(i);
            break;
        }
    }
}
예제 #4
0
void DrawBuffer::Rect(float x, float y, float w, float h, uint32_t color, int align) {
	DoAlign(align, &x, &y, &w, &h);
	RectVGradient(x, y, w, h, color, color);
}