/// <summary> /// /// </summary> /// <param name="pathCollec"></param> private int AnalyseVPrinciple(MvGame[] mvGames) { boxLog.Text += @"AnalyseVPrinciple" + Environment.NewLine; int retour = 0; foreach (MvGame mvG in mvGames) { int lOrgRelat = Analyse.One_Col(x => x.Original_RLink, mvG.GetPaths, bRelatFont).Width; int lOrgHard = Analyse.One_Col(x => x.Original_HLink, mvG.GetPaths, bHardFont).Width; int lDestRelat = Analyse.One_Col(x => x.Destination_RLink, mvG.GetPaths, bRelatFont).Width; int lDestHard = Analyse.One_Col(x => x.Destination_HLink, mvG.GetPaths, bHardFont).Width; int tmp = Math.Max(lOrgRelat, Math.Max(lOrgHard, Math.Max(lDestRelat, lDestHard))); retour = tmp > retour ? tmp : retour; } // int lType = Analyse.Rows(x => x.Type, pathCollec, new Label().Font).Width + 50; // taille de l'image de retour return(retour); }
/// <summary> /// Analyse les propriétés de tout le tableau pour calculer la taille des colonnes /// </summary> /// <param name="folders"></param> private void AnalyseProps(MvFolder[] folders) { boxLog.Text += @"Analysis of columns width" + Environment.NewLine; _Cols = new Dictionary <string, int>(); _Cols.Add("Arrow", 20); // Name of the Media //PropertyInfo propMedia = typeof(MvFolder).GetProperty("MediaType"); _Cols.Add("MediaType", Analyse.One_Col(x => x.MediaType, folders, new Label().Font).Width); // OldPath Size sORelat = Analyse.One_Col(x => x.FolderPath, folders, bRelatFont); Size sOHard = Analyse.One_Col(x => x.HFolderPath, folders, bHardFont); _Cols.Add("UCP1", sOHard.Width > sORelat.Width ? sOHard.Width : sORelat.Width); // NewPath Size sNRelat = Analyse.One_Col(x => x.NewFolderPath, folders, bRelatFont); Size sNHard = Analyse.One_Col(x => x.HNewFolderPath, folders, bHardFont); _Cols.Add("UCP2", sNHard.Width > sNRelat.Width ? sNHard.Width : sNRelat.Width); }