QTabWidget and layout direction problem [Solved]

  • i must change layout direction because i implimented multiple
    languages support in the app but when i change the layout direction
    the "close buttons icons " don't follow the tabs,
    if the tabwidget goes right they stay left and vise versa
    here is the changing layout direction code

    @////after loading and installing the translator
    if (language == "arabic"){

    here is how it looks when i change the layoutdirection


  • it' ok isolved the problem
    i noticed that when i select a tab the
    "close icon " return to its place automaticly
    so i eterate through all the tabs and select
    them one by one each time i change the layout

    @////save the currentindex in index
    int index=ui->projectsTabWidget->currentIndex();
    //iterate and select the tabs
    for(int i=0;i<ui->projectsTabWidget->count()-1;i++)
    //reset the selected tab

    but if you know a better and a practical way,let me know

Log in to reply

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.